Henrik Bengtsson
2007-Aug-28 20:24 UTC
[Rd] R CMD check: Error in function (env) : could not find function "finalize"
Hi, does someone else get this error message: Error in function (env) : could not find function "finalize"? I get an error when running examples in R CMD check (v2.6.0; session info below):> ### * invertMap > > flush(stderr()); flush(stdout()) > ### Name: invertMap > ### Title: Inverts a read or a write map > ### Aliases: invertMap > ### Keywords: file IO internal > > ### ** Examples > > # .... [TRUNCATED] > nbrOfCells <- 2600000 > readMap <- sample(nbrOfCells)Error in function (env) : could not find function "finalize" Error in function (env) : could not find function "finalize" Error in function (env) : could not find function "finalize" Error in function (env) : could not find function "finalize" Error in function (env) : could not find function "finalize" Error in function (env) : could not find function "finalize" The error occurs in R CMD check but also when start a fresh R session and run, in this case, affxparser.Rcheck/affxparser-Ex.R. It always occur on the same line. When I debug(sample), all values passed to the internal function looks fine. I've replaced it with runif() and vector("double", nbrOfCells) and manged to get the error there too. So, it seems like there are some memory issues. I've called gc() just before without success. There are a lot of other example code processed before this one and many of them rely on native code, so it could be a memory leak or something. However, before troubleshooting more, I wanted to hear if someone else got the same problem. Searching google, gives me one hit in a recent Bioconductor build/check. From Google cache http://tinyurl.com/25hkld> ## Perform svdImpute using the 3 largest components > result <- pca(metaboliteData, method="svdImpute", nPcs=3, center = TRUE)Error in function (env) : could not find function "finalize" ... Now, the error is not there. Any ideas? /Henrik> sessionInfo()R version 2.6.0 Under development (unstable) (2007-08-23 r42614) i386-pc-mingw32 locale: LC_COLLATE=English_United States.1252;LC_CTYPE=English_United States.1252;LC_MON ETARY=English_United States.1252;LC_NUMERIC=C;LC_TIME=English_United States.1252 attached base packages: [1] stats graphics grDevices utils datasets methods base other attached packages: [1] affxparser_1.9.5 loaded via a namespace (and not attached): [1] AffymetrixDataTestFiles_0.1.0
Seth Falcon
2007-Aug-29 04:48 UTC
[Rd] R CMD check: Error in function (env) : could not find function "finalize"
Hi Henrik, "Henrik Bengtsson" <hb at stat.berkeley.edu> writes:> Hi, > > does someone else get this error message: > > Error in function (env) : could not find function "finalize"? > > I get an error when running examples in R CMD check (v2.6.0; session > info below):[snip]> The error occurs in R CMD check but also when start a fresh R session > and run, in this case, affxparser.Rcheck/affxparser-Ex.R. It always > occur on the same line.So does options(error=recover) help in determining where the error is coming from? If you can narrow it down, gctorture may help or running the examples under valgrind. + seth -- Seth Falcon | Computational Biology | Fred Hutchinson Cancer Research Center BioC: http://bioconductor.org/ Blog: http://userprimary.net/user/
Seemingly Similar Threads
- R CMD check: non source files in src on (2.3.0 RC (2006-04-19 r37860))
- Dynamic linking to binary code from other packages??
- Suggestion: isLoaded() to test if a package is loaded (without loading it)
- R 2.15.0 alpha: R CMD check --as-cran / tools:::..check_package_CRAN_incoming() crash
- help.start() only recognizes forward slashes in R_LIBS_USER which is not the default case