El 30/6/24 a las 13:28, Ralf Stubner escribió:
Dear all,

On Sun, Jun 23, 2024 at 11:40 PM Juan Domingo Esteve <juan.domi...@uv.es> wrote:
Might it affect many or all the packages that depends on Rcpp (that, I guess, 
are
probably a lot of them)?

I am pretty confident it is not all packages using Rcpp. I have two of
those on CRAN (dqrng and swephR) and got no message concerning those.
Also Winbuilder still works fine for these. And I do make use of
Rcpp::CharacterVector at least in swephR.

Ralf


Dear Ralf:

 Thank you for your kind response, Nevertheless, I'm afraid the problem is more 
serious.
I have just checked my package (scellpam) with Winbuilder, and everything 
_seems_ OK, except
one note saying that "The Date field is over a month old.". If you are curious, 
look at the results
in
https://win-builder.r-project.org/7V4tR60V98W7/

So my package passes the Winbuilder test but not CRAN tests and the problem, I 
guess, might come
from this piece of the source code of R, taken from source file 
src/include/Rinternals.h

/* Rest of this file
   Stuff that is not API and probably should not be but is getting used.
 */

void (SET_TYPEOF)(SEXP x, int v); // used by Rcpp
void (SET_OBJECT)(SEXP x, int v); // used by Rcpp
void (SET_S4_OBJECT)(SEXP x); // used by Rcpp (maybe?)
void (UNSET_S4_OBJECT)(SEXP x); // used by Rcpp (maybe?)
const char *R_curErrorBuf(void); // used by unix */
int (IS_SCALAR)(SEXP x, int type); // used by symengine */
Rboolean Rf_psmatch(const char *, const char *, Rboolean); // used by rgl

As the initial comment says, it seems that if you use any of these functions 
(or use Rcpp which uses it),
you get into trouble with the CRAN maintainers.

My package does not call directly SET_TYPEOF, but a grep inside the library 
that I generate
(libscellpam.so) finds it, so I assume it is called by Rcpp.

Other packages like REndo, maintained by Patrik Scheiller, reported a similar 
error with
function STRING_PTR in a mail recently sent to this list. I am not sure if such 
package would
pass the Winbuilder test, but I guess it would do, so don't be too confident in 
the Winbuilder
test.

The answer of Dirk Edderlbuettel to the former issue pointed me to this page:

https://github.com/RcppCore/Rcpp/issues/1311#user-content-fn-1-0bfb88969ba932d4ddf8e167f9b00c34

where they are reporting the progress on Rcpp. They talk about newer versions 
of Rcpp. Indeed, and
following their suggestion, I have tried to delete Rcpp and install it again 
with

install.packages("Rcpp", repos=c("https://RcppCore.github.io/drat";, 
"https://cloud.r-project.org";))

which installs indeed a newer version and using it I have recompiled and tested 
my package. Everything
seems to work fine (and the package works) but the string SET_TYPEOF is still 
inside the shared library,
so I assume the problem posed by the CRAN maintainers would remain.

 My questions are:

* If you find traces of SET_TYPEOF or any of the functions mentioned before in 
the R source code before,
or of STRING_PTR, inside your libraries, is this likely to provoke a rejection 
from CRAN?
* In the case the problem is in Rcpp, we will have to wait until Dirk and other 
maintainers can fix it, which
obviously will take some time since the problem seems difficult (they announce, 
I think, a new release for July)
But in the meantime, our packages will be retired from CRAN (mine will be 
retired next July 3rd).

First, is this interpretation correct? i.e. is Rcpp the only reason or we have 
done something wrong
in our packages that we should correct?

If Rcpp is the reason:

- Can we (the package maintainers) do something to help, apart of test our 
packages with the new versions of Rcpp
as they are available and report the result?
- Could we do something to convince the CRAN maintainers to allow for an 
extension until issues can be fixed?

  Thanks a lot and sorry for the inconveniences

    Juan

--
________________________________________________________________
Juan Domingo Esteve
Dept. of Informatics, School of Engineering
University of Valencia
Avda. de la Universidad, s/n.
        46100-Burjasot (Valencia)
           SPAIN

Telephone:      +34-963543572
Fax:            +34-963543550
email:  juan.domi...@uv.es
________________________________________________________________
_______________________________________________
Rcpp-devel mailing list
Rcpp-devel@lists.r-forge.r-project.org
https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel

Reply via email to