Re: [Rd] sprintf, check number of parameters

2020-11-04 Thread Tomas Kalibera
Dear Matthias, thanks for the suggestion, R-devel now warns on unused arguments by format (both numbered and un-numbered). It seems that the new warning is useful, often it finds cases when arguments were accidentally passed to sprintf but had been meant for a different function. R allows co

Re: [Rd] sprintf, check number of parameters

2020-11-04 Thread Tomas Kalibera
there is at least one numbered reference. Best Tomas > Regarding the mixture: never heard that this works, and I would > probably not want to use it... > > Your work is much appreciated, thanks again. > > Best regards, > > Matthias > > > Ursprüngliche Na

Re: [Rd] formatting issue with gcc 9.3.0 on Ubuntu on WSL2

2020-11-18 Thread Tomas Kalibera
On 11/17/20 9:34 PM, Bill Dunlap wrote: I just got a new Windows laptop (i7, 10th generation CPU), installed 'Windows Subsystem for Linux 2' and then installed Ubuntu 20.04 and used 'apt-get install' to install packages that the R build seems to require. In particular, I am using gcc version 9.3

Re: [Rd] formatting issue with gcc 9.3.0 on Ubuntu on WSL2

2020-11-18 Thread Tomas Kalibera
On 11/18/20 12:56 PM, Iñaki Ucar wrote: On Wed, 18 Nov 2020 at 10:26, Tomas Kalibera wrote: On 11/17/20 9:34 PM, Bill Dunlap wrote: I just got a new Windows laptop (i7, 10th generation CPU), installed 'Windows Subsystem for Linux 2' and then installed Ubuntu 20.04 and used '

Re: [Rd] .Internal(quit(...)): system call failed: Cannot allocate memory

2020-11-23 Thread Tomas Kalibera
On 11/21/20 6:51 PM, Jan Gorecki wrote: Dear R-developers, Some of the more fat scripts (50+ GB mem used by R) that I am running, when they finish they do quit with q("no", status=0) Quite often it happens that there is an extra stderr output produced at the very end which looks like this: Warn

Re: [Rd] .Internal(quit(...)): system call failed: Cannot allocate memory

2020-11-24 Thread Tomas Kalibera
std_CleanUp (saveact=, status=0, runLast=) at sys-std.c:1243 #3 0x557c593d in R_CleanUp (saveact=saveact@entry=SA_NOSAVE, status=status@entry=0, runLast=) at system.c:87 #4 0x556cc85e in do_quit (call=, op=, args=0x57813f90, rho=) at main.c:1393 -Bill On Mon, Nov 23, 2020 at 3:1

Re: [Rd] issue with print()ing multibyte characters on R 4.0.4

2021-02-17 Thread Tomas Kalibera
Thanks for the report, I can reproduce this on Windows, we'll investigate. Best Tomas On 2/17/21 5:58 AM, Hiroaki Yutani wrote: Hi all, I saw several people on Japanese locale claim that, on R 4.0.4, print() doesn't display Japanese characters correctly. This seems to happen only on Windows an

Re: [Rd] sprintf, check number of parameters

2021-02-22 Thread Tomas Kalibera
Dear Matthias, On 2/6/21 2:11 PM, Matthias Gondan wrote: Dear developers, This is a follow-up from an earlier mail about warnings of unused arguments in sprintf: 1. This should obviously raise an error (and it does): sprintf('%i %i', 1) Fehler in sprintf("%i %i", 1) : zu wenig Argumente [= to

Re: [Rd] sprintf, check number of parameters

2021-02-25 Thread Tomas Kalibera
how to skip a value. Thanks, I've added a sentence to that effect. Best Tomas Duncan Murdoch On 22/02/2021 5:06 a.m., Tomas Kalibera wrote: Dear Matthias, On 2/6/21 2:11 PM, Matthias Gondan wrote: Dear developers, This is a follow-up from an earlier mail about warnings of unused

Re: [Rd] r-devel windows gcc10-UCRT machine questions

2021-03-11 Thread Tomas Kalibera
On 3/11/21 4:21 PM, Dirk Eddelbuettel wrote: I saw two (unchanged, long-existing) tests of main fail narrowly on this new platform (relative to the tolerance argument set). Thanks for already looking at the results. I'd be happy to have a look if you point me to the example. Attempting to chang

Re: [Rd] R extension memory leak detection question

2021-03-15 Thread Tomas Kalibera
On 3/12/21 7:43 PM, xiaoyan yu wrote: I am writing C++ program based on R extensions and also try to test the program with google address sanitizer. I thought if I don't protect the variable from the allocation API such as Rf_allocVector, there will be a memory leak. However, the address sanitiz

Re: [Rd] boneheaded BLAS questions

2021-03-18 Thread Tomas Kalibera
On 3/18/21 3:53 AM, Ben Bolker wrote: Thanks.  I know it's supposed to Just Work (and I definitely appreciate all the work that's gone into making it Just Work 99% of the time!).   I tried --with-lapack, no joy.   Will try to decipher the rules file tomorrow ... This is documented in R Admin

Re: [Rd] boneheaded BLAS questions

2021-03-18 Thread Tomas Kalibera
On 3/18/21 9:15 AM, Tomas Kalibera wrote: On 3/18/21 3:53 AM, Ben Bolker wrote: Thanks.  I know it's supposed to Just Work (and I definitely appreciate all the work that's gone into making it Just Work 99% of the time!).   I tried --with-lapack, no joy.   Will try to decipher the

Re: [Rd] custom allocators, Valgrind and uninitialized memory

2021-03-29 Thread Tomas Kalibera
Hi Andreas, On 3/26/21 8:48 PM, Andreas Kersting wrote: > Hi Dirk, > > Sure, let me try to explain: > > CRAN ran the tests of my > package using R which was configured > --with-valgrind-instrumentation > 0. Valgrind reported many errors > related to the use of supposedly uninitialized memory

Re: [Rd] custom allocators, Valgrind and uninitialized memory

2021-03-30 Thread Tomas Kalibera
y directly from allocVector3(). Regards, Andreas 2021-03-29 10:41 GMT+02:00 "Tomas Kalibera" : Hi Andreas, On 3/26/21 8:48 PM, Andreas Kersting wrote: Hi Dirk, > > Sure, let me try to explain: > > CRAN ran the tests of my package using R which was configured > --wit

Re: [Rd] nchar(x, type = "bytes") seems slower than it could be

2021-03-30 Thread Tomas Kalibera
Thanks for the report, you are probably running into the overhead of the eager creation of the error message. On my system, with your micro-benchmark, it is about 10x. I've tested simply by uncommenting it and re-running the benchmark. I'll fix (this is not a good task for a contributed patch).

Re: [Rd] R CMD check fails with: During startup - Warning message: Setting LC_CTYPE=en_US.UTF-8 failed

2021-04-13 Thread Tomas Kalibera
On 4/13/21 4:36 PM, Witold E Wolski wrote: Hello, I am trying to run a package check on windows 10. But it fails with the following errors: ``` $ R CMD check prolfqua_0.1.5.3.tar.gz During startup - Warning message: Setting LC_CTYPE=en_US.UTF-8 failed * using log directory 'C:/Users/wewol/__che

Re: [Rd] problem adding gdb to RTOOLS40 on Windows

2021-04-15 Thread Tomas Kalibera
On 4/15/21 6:52 AM, Bravington, Mark (Data61, Hobart) wrote: I've not been able to install gdb for RTOOLS40 on Windows 10. The rtools installer (rtools40-x64_86.exe) doesn't seem to include gdb by default, and when I follow the instructions for adding gdb (which I tracked down at https://githu

Re: [Rd] nchar(x, type = "bytes") seems slower than it could be

2021-04-15 Thread Tomas Kalibera
For reference, fixed in R-devel (80153). Tomas On 3/30/21 10:20 AM, Tomas Kalibera wrote: Thanks for the report, you are probably running into the overhead of the eager creation of the error message. On my system, with your micro-benchmark, it is about 10x. I've tested simply by uncomme

Re: [Rd] R 4.0.1-4.0.5 built with Intel Composer 19.0-19.1.1, error in "make check" on CentOS 7.7-7.9

2021-04-17 Thread Tomas Kalibera
Thank you Ryan and Ivan for reporting and debugging this. Godbolt.org shows that icc 19.0.1 with -O2 -ipo (inter-procedural optimizations) is too smart and optimizes this stack growth detection code so that it returns incorrect result on x86_64. Detecting stack growth from C is tricky - in prin

Re: [Rd] R 4.0.1-4.0.5 built with Intel Composer 19.0-19.1.1, error in "make check" on CentOS 7.7-7.9

2021-04-19 Thread Tomas Kalibera
On 4/17/21 6:55 PM, Tomas Kalibera wrote: Thank you Ryan and Ivan for reporting and debugging this. Godbolt.org shows that icc 19.0.1 with -O2 -ipo (inter-procedural optimizations) is too smart and optimizes this stack growth detection code so that it returns incorrect result on x86_64

Re: [Rd] NEWS item for bugfix in normalizePath and file.exists?

2021-04-28 Thread Tomas Kalibera
Hi Toby, a defensive, portable approach would be to use only file names regarded portable by POSIX, so characters including ASCII letters, digits, underscore, dot, hyphen (but hyphen should not be the first character). That would always work on all systems and this is what I would use. Indiv

Re: [Rd] NEWS item for bugfix in normalizePath and file.exists?

2021-04-28 Thread Tomas Kalibera
orrect response from R, in my opinion, would be > c(FALSE, TRUE) -- not an error. > Toby > > On Wed, Apr 28, 2021 at 3:10 AM Tomas Kalibera > mailto:tomas.kalib...@gmail.com>> wrote: > > Hi Toby, > > a defensive, portable approach would be to use only fil

Re: [Rd] NEWS item for bugfix in normalizePath and file.exists?

2021-04-28 Thread Tomas Kalibera
such file names, and after the change Toby reported from ERROR to FALSE, Martin's proposal would change to NA, mine eventually to ERROR, etc. So it is best for now to leave it unspecified and not trigger it, I think. Tomas Martin > On Wed, Apr 28, 2021 at 3:10 AM Tomas Kalibera

Re: [Rd] NEWS item for bugfix in normalizePath and file.exists?

2021-04-28 Thread Tomas Kalibera
his is something that is still relevant after the switch to UTF-8 as native encoding, so something that needs to be fixed fully, and there have been some improvements recently. Tomas On Wed, Apr 28, 2021 at 9:04 AM Tomas Kalibera wrote: On 4/28/21 5:22 PM, Martin Maechler wrote: Toby Hocking

Re: [Rd] Difference in NA behavior in R-devel running under valgrind

2021-04-30 Thread Tomas Kalibera
I can reproduce on my system, running an unoptimized R build (-O0) in valgrind produces NaN (valgrind 3.15.0, gcc 9.3.0 - Ubuntu 20.04/x86_64) for the example, but without valgrind it produces NA. Valgrind modifies the binary code before running it and this is probably what is causing the diff

Re: [Rd] Difference in NA behavior in R-devel running under valgrind

2021-04-30 Thread Tomas Kalibera
] = 0xF7;   f64[5] = f64[4] = f64[3] = f64[2] = f64[1] = f64[0] = 0xFF;    } +  f64[0] = f80[0]; /* R hack: copy NaN payload */ +  f64[1] = f80[1]; +  f64[2] = f80[2]; +  f64[3] = f80[3]; +    return;     } On 4/30/21 10:02 AM, Tomas Kalibera wrote: I can reproduce

Re: [Rd] 1954 from NA

2021-05-23 Thread Tomas Kalibera
TLDR: tagging R NAs is not possible. External software should not depend on how R currently implements NA, this may change at any time. Tagging of NA is not supported in R (if it were, it would have been documented). It would not be possible to implement such tagging reliably with the current

Re: [Rd] 1954 from NA

2021-05-23 Thread Tomas Kalibera
e universe for the social sciences that is > not currently available and which all other major statistical packages > do offer. > > Thank you very much, your attention is greatly appreciated, > Adrian > > On Sun, May 23, 2021 at 7:59 PM Tomas Kalibera > mailto:tomas.kali

Re: [Rd] 1954 from NA

2021-05-24 Thread Tomas Kalibera
On 5/24/21 11:46 AM, Adrian Dușa wrote: > On Sun, May 23, 2021 at 10:14 PM Tomas Kalibera > mailto:tomas.kalib...@gmail.com>> wrote: > > [...] > > Good, but unfortunately the delineation between computation and > non-computation is not always transp

Re: [Rd] Typo in Writing R Extensions

2021-05-31 Thread Tomas Kalibera
Thanks, fixed now Tomas On 5/28/21 6:44 PM, Vincent Goulet via R-devel wrote: Hi, Just noticed this: on line 15296 of the current (master) R-exts.texi (section 7 of the compiled document), one reads would do most likely do different things, to the justifiable Either one of the "do" i

Re: [Rd] small typo in internet.c

2021-06-13 Thread Tomas Kalibera
Thanks, fixed now. Tomas On 6/13/21 1:39 AM, Kevin Ushey wrote: Hello, I spotted a small typo recently in R-devel: $ rg "htto://" src/modules/internet/internet.c 95: warning(_("the 'wininet' method of url() is deprecated for htto:// and https:// URLs")); I suspect 'htto://' should read 'h

Re: [Rd] Small typo in ?NumericConstants

2021-06-13 Thread Tomas Kalibera
Thanks, fixed now. Tomas On 6/12/21 11:32 PM, Vincent Goulet via R-devel wrote: Hi, I stumbled upon this small typo in ?base::NumericConstants: Index: library/base/man/NumericConstants.Rd === --- library/base/man/NumericConstants.

Re: [Rd] Bracketed paste issues on Linux

2021-06-13 Thread Tomas Kalibera
Thanks for the report. Could you please also post output from extSoftVersion() ? What happens if you paste just a smaller part of the code before the long line? Is the output still corrupted? If so, is it corrupted the same way, at the same places? (It seems to be working on my Ubuntu 20.04,

Re: [Rd] Bracketed paste issues on Linux

2021-06-13 Thread Tomas Kalibera
<- > familyar.summaryintercept = drop.intercept)) control$scalePenalty,") > but if I press return and type the closing "}" the code has actually > arrived just fine. The text up to and including that line is 4023 > bytes in size; when trying to add in more, it fails again. &

Re: [Rd] Bracketed paste issues on Linux

2021-06-15 Thread Tomas Kalibera
changed (viz. was enabled in more places) from readline-8.0 to readline-8.1. Finally, please disregard my earlier comment about vim and nano working just fine. They do, but they don't actually use readline (according to ldd), so don't provide a valid comparison. Thanks for your efforts! Ce

Re: [Rd] Should last default to .Machine$integer.max-1 for substring()

2021-06-21 Thread Tomas Kalibera
On 6/21/21 9:35 AM, Martin Maechler wrote: Michael Chirico on Sun, 20 Jun 2021 15:20:26 -0700 writes: > Currently, substring defaults to last=100L, which > strongly suggests the intent is to default to "nchar(x)" > without having to compute/allocate that up front.

Re: [Rd] Should last default to .Machine$integer.max-1 for substring()

2021-06-22 Thread Tomas Kalibera
all, great points well taken. Indeed it seems the default of 100 predates SVN tracking in 1997. I think a NULL default behaving as "end of string" regardless of encoding makes sense and avoids the overheads of a $ call and a much heavier nchar() calculation. Mike C On Mon, Jun 21, 2021

[Rd] R Can Use Your Help: Testing R Before Release

2021-07-13 Thread Tomas Kalibera
If anyone is interested in helping out, this is a good time to test R 4.1.1 before it is released. Now is the time to look for and report - regressions (things that worked in 4.1.0, but not in 4.1.1) - regressions in 4.1.0 not fixed by 4.1.1 - bugs in new features in 4.1.0 not fixed by 4.1.1 Fo

Re: [Rd] User interrupts parallel excution. Why it works or why not?

2021-07-20 Thread Tomas Kalibera
Hi Jiefei, when you run the cluster "automatically" in your terminal and pres Ctrl-C in Unix, both the master and the worker processes get the SIGINT signal, because they belong to the same foreground process group. So you are directly interrupting also the worker process. When you run the c

Re: [Rd] Feature request: Change default library path on Windows

2021-07-27 Thread Tomas Kalibera
On 7/26/21 1:44 AM, Steve Haroz wrote: Thanks Ben. I just sent a request for a bugzilla login. Jeroen chimed in earlier in support. Please note this has been reported, discussed and considered already, last time in PR#17842 (though proposing a different replacement for the default). I think

Re: [Rd] Trivial typo in help("browser")

2021-07-29 Thread Tomas Kalibera
Thanks, fixed now. Tomas On 7/29/21 8:59 AM, Peter Langfelder wrote: I'm also not a native speaker but my take is that a "be" is missing in the sentence and it should read An expression, which if it evaluates to TRUE the debugger will be invoked, otherwise control is returned directly. On Wed,

Re: [Rd] Check if (embedded) R has been initialized from C code

2021-07-29 Thread Tomas Kalibera
Dear Matthias, On 6/17/21 8:25 AM, Matthias Gondan wrote: Dear R developers, (This email has also been sent to R-help before, but I was told that it doesn’t really fit there) I am currently trying to write a piece of C code that uses „embedded R“, and for specific reasons*, I cannot keep tra

Re: [Rd] [External] Re: Update on rtools4 and ucrt support

2021-08-23 Thread Tomas Kalibera
ncoding issues on Windows has been taking an unsustainable amount of R-core resources for some time now. Tomas Kalibera has been taking the lead on trying to address these issues in the existing framework, but this means he has not had the time to make any of the many other valuable and important co

Re: [Rd] [External] Re: Is it a good choice to increase the NCONNECTION value?

2021-08-25 Thread Tomas Kalibera
On 8/25/21 6:05 AM, Simon Urbanek wrote: Luke, sure, adjustment at run-time works just fine, the issue currently is that it is baked-in at compile time so there is no way to adjust it (re-building R is not an option in production environment where this usually happens). That said, I'm still

Re: [Rd] Detect UCRT-built R from within R sessions (and in configure.win)

2021-09-08 Thread Tomas Kalibera
On 9/8/21 2:08 PM, Hiroaki Yutani wrote: Hi, Are there any proper ways to know whether the session is running on the R that is built with the UCRT toolchain or not? Checking if the encoding is UTF-8 might do the trick, but I'm not sure if it's always reliable. There in not such a mechanism,

Re: [Rd] Detect UCRT-built R from within R sessions (and in configure.win)

2021-09-14 Thread Tomas Kalibera
ars.win). Would that work for you? > > Yes, configure.ucrt should work for me. There might be someone who > prefers to switch by some envvar rather than creating another file, > but I don't have a strong opinion here. The experimental builds now support configure.ucrt and clean

Re: [Rd] Detect UCRT-built R from within R sessions (and in configure.win)

2021-09-23 Thread Tomas Kalibera
uot; files back into the ".win". So, in the long term, there should be no conditionals on R.version$crt nor ".ucrt" files. Best Tomas Best, Hiroaki Yutani 2021年9月14日(火) 23:44 Hiroaki Yutani : Thanks for both, I'll try these features. 2021年9月14日(火) 22:40 Tomas Kalibe

Re: [Rd] [External] Re: Workaround very slow NAN/Infinities arithmetic?

2021-10-06 Thread Tomas Kalibera
On 10/1/21 6:07 PM, Brodie Gaslam via R-devel wrote: On Thursday, September 30, 2021, 01:25:02 PM EDT, wrote: On Thu, 30 Sep 2021, brodie gaslam via R-devel wrote: André, I'm not an R core member, but happen to have looked a little bit at this issue myself.  I've seen similar things on Sk

Re: [Rd] Fwd: Using existing envars in Renviron on friendly Windows

2021-10-18 Thread Tomas Kalibera
On 10/15/21 6:44 PM, Michał Bojanowski wrote: Perhaps a small update to ?.Renviron would be in order to mention that... Would you have a more specific suggestion how to update the documentation? Please note that it already says "‘value’ is then processed in a similar way to a Unix shell: i

Re: [Rd] Fwd: Using existing envars in Renviron on friendly Windows

2021-10-27 Thread Tomas Kalibera
ed behavior that is the same as in POSIX shells is the best choice for future compatibility. Tomas > On Mon, Oct 18, 2021 at 5:02 PM Tomas Kalibera wrote: >> >> >> On 10/15/21 6:44 PM, Michał Bojanowski wrote: >> > Perha

Re: [Rd] Fwd: Using existing envars in Renviron on friendly Windows

2021-10-31 Thread Tomas Kalibera
;I think the Renviron files should be written in a way so that they would work the same in a POSIX shell". This is why single quotes. With double quotes, backslashes are interpreted differently from a POSIX shell. Tomas /Henrik On Wed, Oct 27, 2021 at 11:45 AM Tomas Kalibera

Re: [Rd] Fwd: Using existing envars in Renviron on friendly Windows

2021-11-03 Thread Tomas Kalibera
r\AppData\Roaming\R-library] and $ source .Renviron $ echo "R_LIBS_USER=[${R_LIBS_USER}]" R_LIBS_USER=[C:\Users\foobar\AppData\Roaming\R-library] Yes, that could be mentioned explicitly as well. Tomas /Henrik On Sun, Oct 31, 2021 at 2:59 AM Tomas Kalibera wrote: On 10/31/21 2:55

Re: [Rd] Fwd: Using existing envars in Renviron on friendly Windows

2021-11-04 Thread Tomas Kalibera
Thanks for the suggestions, I've updated the documentation. Tomas On 11/3/21 11:30 AM, Tomas Kalibera wrote: On 11/3/21 1:37 AM, Henrik Bengtsson wrote: Oh, I see, I misunderstood.  Thanks for clarifying. One more thing, to mix-and-match environment variables and strings with es

Re: [Rd] gettext(msgid, domain="R") doesn't work for some 'msgid':s

2021-11-05 Thread Tomas Kalibera
On 11/5/21 4:12 PM, Duncan Murdoch wrote: On 05/11/2021 10:51 a.m., Henrik Bengtsson wrote: I'm trying to reuse some of the translations available in base R by using:    gettext(msgid, domain="R") This works great for most 'msgid's, e.g. $ LANGUAGE=de Rscript -e 'gettext("cannot get workin

Re: [Rd] How is the environment variable "R_USER" defined?

2021-11-22 Thread Tomas Kalibera
On 11/22/21 7:06 PM, Jiefei Wang wrote: Thanks for all your help!! It actually has nothing to do with the environment variables. The issue is caused by the backup feature in Onedrive as Bill suggested. I do not know what magic trick Onedrive uses here but it misadvices R to use its directory, n

[Rd] R/CRAN switch to UCRT on Windows

2021-12-08 Thread Tomas Kalibera
Please note an update concerning the support of UTF-8 as native encoding on Windows, which may at this point be of interest particularly to developers of packages with native code and to R users using R-devel (the development version of R) on Windows: https://developer.r-project.org/Blog/publi

Re: [Rd] Question about the UCRT switch

2021-12-09 Thread Tomas Kalibera
On 12/9/21 3:30 PM, Therneau, Terry M., Ph.D. via R-devel wrote: The connected blog has the statement  "Most authors will not have to do anything as the number of CRAN packages that will need some attention is below 1%, but authors of packages using native (C, C++ or Fortran) code should read

Re: [Rd] Feature request: Change default library path on Windows

2021-12-13 Thread Tomas Kalibera
can use e.g. shell.exec() from R. Best Tomas On 7/27/21 1:12 PM, Tomas Kalibera wrote: On 7/26/21 1:44 AM, Steve Haroz wrote: Thanks Ben. I just sent a request for a bugzilla login. Jeroen chimed in earlier in support. Please note this has been reported, discussed and considered already, last

Re: [Rd] MS Windows: R does not escape quotes in CLI options the same way as Rterm and Rscript

2021-12-16 Thread Tomas Kalibera
On 12/15/21 10:48 PM, Henrik Bengtsson wrote: On MS Windows 10, the following works: Rscript --vanilla -e "\"abc\"" [1] "abc" and also: Rterm --vanilla --no-echo -e "\"abc.txt\"" [1] "abc.txt" whereas attempting the same with 'R' fails; R --vanilla --no-echo -e "\"abc.txt\"" Error: o

Re: [Rd] Rtools42 and included libraries

2021-12-20 Thread Tomas Kalibera
On 12/17/21 8:32 PM, Winston Chang wrote: Rtools42 includes the pre-compiled libraries needed to build most CRAN packages. From the blog ( https://developer.r-project.org/Blog/public/2021/12/07/upcoming-changes-in-r-4.2-on-windows/ ): Most of the required package changes were due to downloadi

Re: [Rd] R on Windows with UCRT and the system encoding

2021-12-21 Thread Tomas Kalibera
Hi Yutani, On 12/21/21 6:34 AM, Hiroaki Yutani wrote: Hi, I'm more than excited about the announcement about the upcoming UTF-8 R on Windows. Let me confirm my understanding. Is R 4.2 supposed to work on Windows with non-UTF-8 encoding as the system locale? I think this blog post indicates so (

Re: [Rd] R on Windows with UCRT and the system encoding

2021-12-21 Thread Tomas Kalibera
clipboard apparently contains the Unicode characters, but R does not get them correctly, and from my quick read, it is a bug in R. My guess is this is in connections.c, where we call GetClipboardData(CF_TEXT). Perhaps if we used CF_UNICODETEXT, it would work (or alternatively CF_TEXT but als

Re: [Rd] MS Windows: R does not escape quotes in CLI options the same way as Rterm and Rscript

2021-12-22 Thread Tomas Kalibera
Now fixed in R-devel Best Tomas On 12/16/21 10:22 AM, Tomas Kalibera wrote: On 12/15/21 10:48 PM, Henrik Bengtsson wrote: On MS Windows 10, the following works: Rscript --vanilla -e "\"abc\"" [1] "abc" and also: Rterm --vanilla --no-echo -e "\

Re: [Rd] "getOption(max.print) omitted %d entries" may be negative

2022-01-03 Thread Tomas Kalibera
On 1/3/22 6:15 PM, Martin Maechler wrote: Hugh Parsonage on Wed, 29 Dec 2021 00:36:51 +1100 writes: > In src/main/printvector.c in the definition of printVector and > printNamedVector (and elsewhere): > Rprintf(" [ reached getOption(\"max.print\") -- omitted %d entries ]\

Re: [Rd] gsub() hex character range problems in R-devel?

2022-01-05 Thread Tomas Kalibera
Hi Martin, I'd add few comments to the excellent analysis of Brodie. - \xhh is allowed and defined in Perl regular expressions, see ?regex (would need perl=TRUE), but to enter that in an R string, you need to escape the backslash. - \xhh is not defined by POSIX for extended regular expressio

Re: [Rd] symbols.rds error 1

2022-04-05 Thread Tomas Kalibera
On 4/5/22 15:25, Ivan Krylov wrote: On Tue, 5 Apr 2022 15:08:10 +0200 Roman Savchenko wrote: Error in system(sprintf("%s -Pg %s", nm, shQuote(f)), intern = TRUE) : '""' not found This does highlight a minor bug in R (an empty string is accidentally quoted, so the absence of nm on the PAT

Re: [Rd] calloc() vs. R_Calloc()

2022-04-07 Thread Tomas Kalibera
On 4/7/22 08:59, Adrian Dușa wrote: Dear R devs, I ran into a C level problem that hopefully is a quick fix to a trained eye. Not sure if I am able to produce a minimal reproducible example, but suppose a (test) package passes all the local tests, passes the R CMD check and also passes the te

Re: [Rd] calloc() vs. R_Calloc()

2022-04-07 Thread Tomas Kalibera
On 4/7/22 10:32, Adrian Dușa wrote: > On Thu, 7 Apr 2022 at 10:32, Tomas Kalibera > wrote: > > > [...] > > And what are the errors you run into? On which platforms, under what > circumstances, etc? It would be much easier to give advice knowing > that

Re: [Rd] Rgui.exe 4.2.0 does not receive characters via the Windows API's PostMessage function

2022-05-06 Thread Tomas Kalibera
On 5/6/22 07:03, jcfaria wrote: Dear Duncan, I believe the problem is of a different nature. I get TRUE 3 times running the code below: procedure TfMain.btnPasteClick(Sender: TObject); var   i: integer;   sTmp: string;   hBN: HWND;   j: bool; begin   hBN:= FindWindowA(nil,    

Re: [Rd] Rgui.exe 4.2.0 does not receive characters via the Windows API's PostMessage function

2022-05-16 Thread Tomas Kalibera
s Best, ///\\\///\\\///\\\///\\\///\\\///\\\///\\\///\\\///\\\///\\\ Jose Claudio Faria UESC/DCET/Brasil joseclaudio.faria at gmail.com Telefones: 55(73)3680.5545 - UESC 55(73)99966.9100 - VIVO ///\\\///\\\///\\\///\\\///\\\///\\\///\\\///\\\///\\\///\\\ If you have software to deal with statisti

Re: [Rd] Writing in R // R 4.2.0 on Windows doesn't work with Dasher

2022-05-16 Thread Tomas Kalibera
rds, Paulo Barata -- On 16/05/2022 14:08, Tomas Kalibera wrote: On 5/15/22 16:10, Paulo Barata wrote: To the R developers, I noticed today that R 4.2.0 responds to the "Enter" character of Dasher version 5.0.0 beta in "Direct Entry" mo

Re: [Rd] Trying to compile R 4.2.x on Linux as 32bit sub-architecture

2022-06-20 Thread Tomas Kalibera
On 6/20/22 15:40, Berwin A Turlach wrote: G'day Tomas, On Mon, 20 Jun 2022 14:46:04 +0200 Tomas Kalibera wrote: Well, what puzzles me is that I had no problem with R-patched right until the end of the 4.1 branch. And I have no problems with R-devel, that is also still installing a

Re: [Rd] R-Devel (82603) still passing "fno-optimize-sibling-calls" on Windows

2022-07-18 Thread Tomas Kalibera
On 7/18/22 19:14, Avraham Adler wrote: Hello. According to my understanding of the changes in R-devel, the flag -fno-optimize-sibling-calls should no longer be forced when compiling R. Yet, as I compile R, revision 82603, from source on Windows (Skylake-X server) I see the flag being passed (e

Re: [Rd] R_check_class_etc(x, valid) is "slow" when 'valid' contains class(x)

2022-09-02 Thread Tomas Kalibera
Hi Mikael, On 8/28/22 01:13, Mikael Jagan wrote: R_check_class_etc(x, valid) spends a nontrivial amount of time finding an environment 'rho' containing the definition of class(x), evaluating (in R, not C) methods::.classEnv(class(x)). It then returns the result of R_check_class_and_super(x, val

Re: [Rd] Problem with accessibility in R 4.2.0 and 4.2.1.

2022-09-22 Thread Tomas Kalibera
On 9/22/22 18:24, peter dalgaard wrote: Tomas Kalibera has related that he has some scars from fighting with some unexpected interactions between UTF-8 and the GraphApp library that is used for RGui and I think he said that screen readers were involved. I wouldn't be surprised if this

Re: [Rd] Problem with accessibility in R 4.2.0 and 4.2.1.

2022-09-22 Thread Tomas Kalibera
know why I hadn't seen Andrew's first message given I get other list traffic. Jonathan -Original Message- From: peter dalgaard Sent: Friday, 23 September 2022 4:24 am To: Andrew Hart Cc: R-devel@r-project.org; Tomas Kalibera ; Jonathan Godfrey Subject: Re: [Rd] Problem with

Re: [Rd] Problem with accessibility in R 4.2.0 and 4.2.1.

2022-09-25 Thread Tomas Kalibera
On 9/22/22 23:15, Andrew Hart via R-devel wrote: On 22/09/2022 16:42, Toby Hocking wrote: Another option is to use https://emacspeak.sourceforge.net/ (version of emacs editor/ide which can speak letters/words/lines -- has a blind maintainer) with http

Re: [Rd] Proposal to limit Internet access during package load

2022-09-27 Thread Tomas Kalibera
On 9/27/22 18:42, Blätte, Andreas wrote: Dear all, my apologies for a dull question. I think I do understand that unnoticed Internet access requires scrutiny and a more explicit approach. But I am not sure how this would impact on the practice on many Windows machines to download static libra

Re: [Rd] Installation failure in non-UTF-8 MBCS locale

2022-10-17 Thread Tomas Kalibera
On 10/16/22 19:35, Gábor Csárdi wrote: I am sorry, part of the output is garbled, as the email's encoding is different, but the error is hopefully still clear. This is Ubuntu 20.04, yesterday's R devel or R release, in the zh_CN locale. The zh_CN.UTF-8 locale is fine, and it is a much better

Re: [Rd] RTools40 Error - sh: line 1: gcc: command not found

2022-11-29 Thread Tomas Kalibera
On 11/28/22 23:33, Gene Leynes wrote: Thanks. Not sure how I ended up on 40 instead of 42. After deleting the 40 version and installing the 42 version, the 42 installer seemed to create path variables for 40. I just edited that however and the jsonlite test worked. Rtools42 is not creating var

Re: [Rd] [R] I do not want that R CMD build removes temp directory

2022-12-19 Thread Tomas Kalibera
On 12/19/22 11:08, Uwe Ligges wrote: Ah, before that you wrote "" ERROR: lazy loading failed for package 'prolfqua' * removing 'C:Users " and C:Users  without a slash sonds suspicious. Now with the new output I do not see where the issue is from. Does this also happen when you try it on win

Re: [Rd] Problem with accessibility in R 4.2.0 and 4.2.1.

2022-12-20 Thread Tomas Kalibera
On 9/22/22 23:15, Andrew Hart via R-devel wrote: On 22/09/2022 16:42, Toby Hocking wrote: Another option is to use https://emacspeak.sourceforge.net/ (version of emacs editor/ide which can speak letters/words/lines -- has a blind maintainer) with http

Re: [Rd] Problem with accessibility in R 4.2.0 and 4.2.1.

2022-12-20 Thread Tomas Kalibera
Dear Andrew, Jonathan, I had a closer look and tried to improve accessibility in Rgui, please see below. I would be grateful for feedback. Rgui supports three cursor types, which can be selected via Edit/GUI preferences/Cursor blink. The default is "partial", but for screen readers, please

Re: [Rd] Problem with accessibility in R 4.2.0 and 4.2.1.

2022-12-21 Thread Tomas Kalibera
n 4.2.2. Also, I'll download the development snapshot and try it out. I'll let you know how I get on. Please excuse me if I don't get to it immediately; things are a bit crazy at work at the moment and it is that time of the year too! Cheers, Andrew. On 20/12/2022 19:33, To

Re: [Rd] Problem with accessibility in R 4.2.0 and 4.2.1.

2022-12-22 Thread Tomas Kalibera
was the disconnect with the screen reader. Did the underlying development toolbox undergo any version changes from ( <4.2.0 ) to (4.2.0...4.2.1) to (4.2.2) ?? Great that normal transmission has resumed. Jonathan -Original Message- From: Tomas Kalibera Sent: Thursday, 22 December 2022

Re: [Rd] RTools 4.2 - possible conflict with git bash

2022-12-23 Thread Tomas Kalibera
On 12/23/22 15:45, sergio.vign...@unibe.ch wrote: Hi all, It seems that RTools 4.2 conflicts with git bash on Windows 10. You can't mix tools from two different distributions based on msys2 (or cygwin). You cannot e.g. call "make" of one of them from a shell ran in another one. This is due t

Re: [Rd] Problem installing gdb into Rtools42

2023-01-17 Thread Tomas Kalibera
On 1/18/23 04:33, Dominick Samperi wrote: Hello, I tried installing gdb into Rtools42 following the instructions here https://cran.r-project.org/bin/windows/base/howto-R-4.2.html I ran 'pacman -Sy gdb', and the installation seemed to complete without problems. But gdb could not be started be

Re: [Rd] Problem installing gdb into Rtools42

2023-01-18 Thread Tomas Kalibera
ls42 comes with Msys2. gdb is not installed there by default, because most people don't need it, but it is documented how to install it. I've now updated the documentation to always remind to update the system before installing any Msys2 packages. Tomas > > Dominick > >

Re: [Rd] Problem installing gdb into Rtools42

2023-01-18 Thread Tomas Kalibera
s://gitlab.haskell.org/ghc/ghc/-/issues/19945. From a quick look it seems to be an incompatibility between two libraries implementing POSIX regular expressions, essentially a name clash, they just need to make sure to consistently use one of them. It is not a problem of MinGW-W64. Tomas

Re: [Rd] Problem installing gdb into Rtools42

2023-01-19 Thread Tomas Kalibera
btle issue in the repl program under >> Windows >> that is not related to gdb, but this doesn't explain why gdb >> creates that stray >> thread, making it impossible to proceed with the debugging. Nothing >> should happen before gdb hits

Re: [Rd] Object are not destroy while using error (Rf_error)

2023-01-23 Thread Tomas Kalibera
On 1/21/23 16:55, Antoine Lucas wrote: Dear all, I try to understand why on my computer I do not clear all data with this code: #include static int count = 0; class A { public: A(){ printf("c %d\n", count); count++; } ~A(){count--; printf("d %d\n", count); } }; extern

Re: [Rd] Sys.getenv(): Error in substring(x, m + 1L) : invalid multibyte string at '' if an environment variable contains \xFF

2023-01-30 Thread Tomas Kalibera
On 1/30/23 23:01, Henrik Bengtsson wrote: /Hello. SUMMARY: $ BOOM=$'\xFF' LC_ALL=en_US.UTF-8 Rscript --vanilla -e "Sys.getenv()" Error in substring(x, m + 1L) : invalid multibyte string at '' $ BOOM=$'\xFF' LC_ALL=en_US.UTF-8 Rscript --vanilla -e "Sys.getenv('BOOM')" [1] "\xff" BACKGROUND: I

Re: [Rd] Sys.getenv(): Error in substring(x, m + 1L) : invalid multibyte string at '' if an environment variable contains \xFF

2023-01-31 Thread Tomas Kalibera
ld two different results. I would argue that if we want to make specific checks, we should make them conditional - even if the default is to add them. Again, the error is due to the implementation of Sys.getenv() breaking in R-devel, not due to any design decision. The key design decision (a

Re: [Rd] Sys.getenv(): Error in substring(x, m + 1L) : invalid multibyte string at '' if an environment variable contains \xFF

2023-01-31 Thread Tomas Kalibera
On 1/31/23 09:48, Ivan Krylov wrote: Can we use the "bytes" encoding for such environment variables invalid in the current locale? The following patch preserves CE_NATIVE for strings valid in the current UTF-8 or multibyte locale (or non-multibyte strings) but sets CE_BYTES for those that are i

Re: [Rd] Sys.getenv(): Error in substring(x, m + 1L) : invalid multibyte string at '' if an environment variable contains \xFF

2023-01-31 Thread Tomas Kalibera
On 1/31/23 11:50, Martin Maechler wrote: Tomas Kalibera on Tue, 31 Jan 2023 10:53:21 +0100 writes: > On 1/31/23 09:48, Ivan Krylov wrote: >> Can we use the "bytes" encoding for such environment variables invalid >> in the current locale? The

Re: [Rd] Sys.getenv(): Error in substring(x, m + 1L) : invalid multibyte string at '' if an environment variable contains \xFF

2023-01-31 Thread Tomas Kalibera
On 1/31/23 14:37, peter dalgaard wrote: On 31 Jan 2023, at 12:51 , Tomas Kalibera wrote: On 1/31/23 11:50, Martin Maechler wrote: hmm.., that's a pity; I had hoped it was a pragmatic and valid strategy, but of course you are right that type stability is really a valid goal...

Re: [Rd] Small typo in Writing R Extensions

2023-02-08 Thread Tomas Kalibera
On 2/8/23 21:33, Davis Vaughan via R-devel wrote: Hi all, Writing R Extensions describes `R_NewEnv()` as: ``` At times it may also be useful to create a new environment frame in C code. R_NewEnv is a C version of the R function new.env: SEXP R_NewEnv(SEXP enclos, int hash, ins size) ``` The

Re: [Rd] long path names (more than 260 chars) not working under Windows OS, longPathAware missing in exe manifests?

2023-02-14 Thread Tomas Kalibera
On 2/14/23 12:11, Roman Hille wrote: Can you help please? All file und dir funktions and also basename() do not work in R under Windows OS if the path is longer than 260 characters. The problem seems to be, that the manifest for all R executables do not have the longPathAware switch in the mani

Re: [Rd] Question on non-blocking socket

2023-02-15 Thread Tomas Kalibera
process between sending the credentials to the server and requesting the status. Tomas Kalibera put me on the right track by drawing my attention to the 'socketSelect' function. I don't know exactly the purpose of this function is (the function itself is documented, but I can't

<    1   2   3   4   5   >