[Rcpp-devel] Fwd: CRAN submission growfunctions 0.1

Dirk Eddelbuettel edd at debian.org
Sat Aug 9 20:59:06 CEST 2014


On 9 August 2014 at 14:31, terrance savitsky wrote:
| Dirk,  Thanks much for taking the time to investigate this issue.  I've created
| a package (sparseList_1.0.tar.gz) with a minimal example of what writing from a
| list of dgCMatrix matrices at the R layer to a field<sp_mat>.  I had intended
| to install boot2docker and use load your R-devel set-up to a container so that
| I could replicate the ASAN-generated error.  Its taking me longer than I'd
| hoped, however, so - for now - I include the package tarball with the minimal
| example and also an R script (sparse_list_to_field.R) so that you may see what
| the function does. 

Thanks -- that is very constructive, and what I was about to suggest.   But
there is one bit missing:  Data tickling the bug.  Can you create a next
version which actually has such matrices (maybe created via package Matrix as
growfunctions seems to do) ?

Your current package checks out fine for lack of actual data.  What is copied
below is R-devel _with_ the -fsanitize=address instrumentation used by Prof
Ripley to find the issue in growfunctions. 

This is not replicated here. We need input data, preferably of the same type
as in growfunction.  You could just saveRDS() one such object and load it here...

Dirk

root at d1244fede37b:/tmp# Rdevel CMD INSTALL sparseList_1.0.tar.gz     
* installing to library '/usr/local/lib/R/site-library'
* installing *source* package 'sparseList' ...
** libs
g++-4.9 -fsanitize=address -I/usr/local/lib/R/include -DNDEBUG  -I/usr/local/include -I"/usr/local/lib/R/site-library/Rcpp/include" -I"/usr/local/lib/R/site-library/RcppArmadillo/include"   -fpic  -pipe -Wall -pedantic -O3  -c RcppExports.cpp -o RcppExports.o
g++-4.9 -fsanitize=address -I/usr/local/lib/R/include -DNDEBUG  -I/usr/local/include -I"/usr/local/lib/R/site-library/Rcpp/include" -I"/usr/local/lib/R/site-library/RcppArmadillo/include"   -fpic  -pipe -Wall -pedantic -O3  -c sparse_list_to_field.cpp -o sparse_list_to_field.o
g++-4.9 -fsanitize=address -shared -L/usr/local/lib/R/lib -L/usr/local/lib -o sparseList.so RcppExports.o sparse_list_to_field.o -L/usr/local/lib/R/lib -lR
installing to /usr/local/lib/R/site-library/sparseList/libs
** R
** preparing package for lazy loading
** help
Warning: /tmp/RtmpcZXqxV/R.INSTALLf9d1c337db7/sparseList/man/sparseList-package.Rd:30: All text must be in a section
Warning: /tmp/RtmpcZXqxV/R.INSTALLf9d1c337db7/sparseList/man/sparseList-package.Rd:31: All text must be in a section
*** installing help indices
** building package indices
** testing if installed package can be loaded
* DONE (sparseList)
root at d1244fede37b:/tmp# 
root at d1244fede37b:/tmp# 
root at d1244fede37b:/tmp# 
root at d1244fede37b:/tmp# Rdevel CMD check sparseList_1.0.tar.gz 
* using log directory '/tmp/sparseList.Rcheck'
* using R Under development (unstable) (2014-08-05 r66309)
* using platform: x86_64-unknown-linux-gnu (64-bit)
* using session charset: ASCII
* checking for file 'sparseList/DESCRIPTION' ... OK
* checking extension type ... Package
* this is package 'sparseList' version '1.0'
* checking package namespace information ... OK
* checking package dependencies ... OK
* checking if this is a source package ... OK
* checking if there is a namespace ... OK
* checking for executable files ... OK
* checking for hidden files and directories ... OK
* checking for portable file names ... OK
* checking for sufficient/correct file permissions ... OK
* checking whether package 'sparseList' can be installed ... WARNING
Found the following significant warnings:
  Warning: /tmp/sparseList.Rcheck/00_pkg_src/sparseList/man/sparseList-package.Rd:30: All text must be in a section
  Warning: /tmp/sparseList.Rcheck/00_pkg_src/sparseList/man/sparseList-package.Rd:31: All text must be in a section
See '/tmp/sparseList.Rcheck/00install.out' for details.
* checking installed package size ... OK
* checking package directory ... OK
* checking DESCRIPTION meta-information ... NOTE
Versioned 'LinkingTo' values for
  'Rcpp' 'RcppArmadillo'
are only usable in R >= 3.0.2
* checking top-level files ... OK
* checking for left-over files ... OK
* checking index information ... OK
* checking package subdirectories ... OK
* checking R files for non-ASCII characters ... OK
* checking R files for syntax errors ... OK
* checking whether the package can be loaded ... OK
* checking whether the package can be loaded with stated dependencies ... OK
* checking whether the package can be unloaded cleanly ... OK
* checking whether the namespace can be loaded with stated dependencies ... OK
* checking whether the namespace can be unloaded cleanly ... OK
* checking loading without being on the library search path ... OK
* checking dependencies in R code ... OK
* checking S3 generic/method consistency ... OK
* checking replacement functions ... OK
* checking foreign function calls ... OK
* checking R code for possible problems ... OK
* checking Rd files ... WARNING
prepare_Rd: sparseList-package.Rd:30: All text must be in a section
prepare_Rd: sparseList-package.Rd:31: All text must be in a section
prepare_Rd: sparseList-package.Rd:37-39: Dropping empty section \examples
* checking Rd metadata ... OK
* checking Rd cross-references ... WARNING
Unknown package '<pkg>' in Rd xrefs
* checking for missing documentation entries ... WARNING
Undocumented code objects:
  'manip_sparseList'
All user-level objects in a package should have documentation entries.
See the chapter 'Writing R documentation files' in the 'Writing R
Extensions' manual.
* checking for code/documentation mismatches ... WARNING
Functions or methods with usage in documentation object 'rcpp_hello_world' but not in code:
  rcpp_hello_world

* checking Rd \usage sections ... OK
* checking Rd contents ... OK
* checking for unstated dependencies in examples ... OK
* checking line endings in C/C++/Fortran sources/headers ... OK
* checking line endings in Makefiles ... OK
* checking for portable use of $(BLAS_LIBS) and $(LAPACK_LIBS) ... OK
* checking compiled code ... OK
* checking examples ... OK
* checking PDF version of manual ... OK

WARNING: There were 5 warnings.
NOTE: There was 1 note.
See
  '/tmp/sparseList.Rcheck/00check.log'
for details.

root at d1244fede37b:/tmp# 



| Terrance​
| [icon_10_ge] sparse_list_to_field.R
| ​​
| [icon_10_ge] sparseList_1.0.tar.gz
| ​​
| ​ 
| 
| 
| On Sat, Aug 9, 2014 at 11:50 AM, Dirk Eddelbuettel <edd at debian.org> wrote:
| 
| 
|     Terrance,
| 
|     So I took a look with one of the prebuilt versions of R using the Docker
|     container I prepare (see the blog / sanitizers write-up I linked to) as I
|     realized that we had a Rcpp Gallery post similar to what that as<>
|     conversion
|     does.
| 
|     And no issue with that code.
| 
|     >From a brief look at your package it seems like you are pushing the
|     envelope
|     a lot harder with fields and list of sparse matrices ( in dpmix.cpp, where
|     another ASAN log pointed to ) so you may have to debug around there.
| 
|     A small reproducible example would surely help us. So far I don't have one
|     for as<sp_mat>.
|    
|     Dirk
|    
|     --
|     http://dirk.eddelbuettel.com | @eddelbuettel | edd at debian.org
| 
| 
| 
| 
| --
| Thank you, Terrance Savitsky

-- 
http://dirk.eddelbuettel.com | @eddelbuettel | edd at debian.org


More information about the Rcpp-devel mailing list