[R-pkg-devel] strange errors (non-ascii symbols) on win-builder R-devel

Maxim Nazarov m@x|m@n@z@rov @end|ng |rom open@n@|yt|c@@eu
Tue Jan 24 18:33:10 CET 2023


Thank you, Tomas, for your insights!

I think I found the root cause of the problem - my package uses the `nlsLM` function from the `minpack.lm` package and coincidentally the new version of that package was submitted to CRAN recently.
Looking at https://win-builder.r-project.org/incoming_pretest/minpack.lm_1.2-3_20230117_110122/reverseDependencies/changes.txt - we can see that this new version of minpack.lm is causing similar errors in many of its reverse dependencies.

In fact if I install that version from https://cran.r-project.org/incoming/archive/ I get the strange output when running a simple example from `nlsLM` even on linux:
```
install.packages("https://cran.r-project.org/incoming/archive/minpack.lm_1.2-3.tar.gz")
library(minpack.lm)
DNase1 <- subset(DNase, Run == 1)
capture.output(fm1DNase1 <- nlsLM(density ~ SSlogis(log(conc), Asym, xmid, scal), DNase1))
## produces "\xa8\002\x8c\003\x9bU"
```
this seems to come from the C code, which I don't fully understand.

So I guess it is an unfortunate timing, and I just need to wait for the minpack.lm package to be fixed, but I'm wondering (philosophically) if it is correct that my package is checked against non-released (non-approved) version of minpack.lm and rejected because of its shortcomings?

Kind regards,
Maxim Nazarov


----- Original Message -----
From: "Tomas Kalibera" <tomas.kalibera using gmail.com>
To: "Maxim Nazarov" <maxim.nazarov using openanalytics.eu>, "r-package-devel" <r-package-devel using r-project.org>
Sent: Monday, 23 January, 2023 21:49:56
Subject: Re: [R-pkg-devel] strange errors (non-ascii symbols) on win-builder R-devel

On 1/23/23 17:30, Maxim Nazarov wrote:
> Hello all,
>
> I am submitting a minor update to one of my CRAN package (BIGL), and get strange errors on R-devel on win-builder - https://win-builder.r-project.org/incoming_pretest/BIGL_1.6.7_20230119_225109/Windows/00check.log and https://win-builder.r-project.org/o339zPAR6pWG/00check.log (different symbols)
>
> It shows strange output like "`1Y���hA�..." before tests and cryptic error-messages like "unable to translate '(<be><b1><a7>m' to a wide string"
> I can also see similar output in examples - https://win-builder.r-project.org/o339zPAR6pWG/examples_and_tests/BIGL-Ex.Rout

These are errors and warnings in regex operations (grep, gsub) due to 
that the input data is not a valid string (validly encoded string). 
Because it is not valid, it cannot be converted to a wide string, which 
is needed for the regex operation, as this uses TRE.

So, you need to find out why the input strings are invalid. Common 
causes of such problems are that they are in a different encoding from 
the one told to R or to some other software on the way. Also the data 
may be corrupted.

> I don't get any isses on debian R-devel, on R-release on windows, and also can't reproduce the errors locally on a windows machine with R-devel, so I am a bit lost.
> Would anyone have any idea of what goes wrong?

It should be fairly easy from the error output to find out which 
operations have failed in the vignette. Perhaps you could find out how 
their inputs were generated.

If you have a Windows machine with R running in UTF-8 as the native 
encoding, with recent R-devel, and the error is still not reproducible, 
try to confirm that the inputs for the failing operations are correct.

Best
Tomas

>
> Kind regards,
> Maxim Nazarov
>
> ______________________________________________
> R-package-devel using r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-package-devel



More information about the R-package-devel mailing list