[Rd] R-2.15.1 CMD CHECK output: "Call Sequence"

2012-10-20 Thread Mark Cowley
Hi guRus,
i'm running R-2.15.1 and the R CMD CHECK output appears to have changed 
substantially, in that instead of pointing me to the offending functions or 
files, I get lots of 'call sequence' traces as below.

I've been using R CMD CHECK for years &  never seen anything like this before. 
This is on a pretty fresh OSX 10.8 Mountain Lion installation, where I 
installed R from CRAN via pkg. Is this a problem unique to me?

cheers,
Mark

heres' a snippet from testing one of my packages under development:

* checking for unstated dependencies in R code ... WARNING
Error: package/namespace load failed for ‘metaGSEA’
Call sequence:
2: stop(gettextf("package/namespace load failed for %s", sQuote(package)), 
  call. = FALSE, domain = NA)
1: library(package, lib.loc = lib.loc, character.only = TRUE, verbose = FALSE)
Execution halted
See the information on DESCRIPTION files in the chapter ‘Creating R
packages’ of the ‘Writing R Extensions’ manual.
* checking S3 generic/method consistency ... WARNING
Error: package/namespace load failed for ‘metaGSEA’
Call sequence:
2: stop(gettextf("package/namespace load failed for %s", sQuote(package)), 
  call. = FALSE, domain = NA)
1: library(package, lib.loc = lib.loc, character.only = TRUE, verbose = FALSE)
Execution halted
See section ‘Generic functions and methods’ of the ‘Writing R
Extensions’ manual.
* checking replacement functions ... WARNING
Error: package/namespace load failed for ‘metaGSEA’
Call sequence:
2: stop(gettextf("package/namespace load failed for %s", sQuote(package)), 
  call. = FALSE, domain = NA)
1: library(package, lib.loc = lib.loc, character.only = TRUE, verbose = FALSE)
Execution halted
The argument of a replacement function which corresponds to the right
hand side must be named ‘value’.
* checking foreign function calls ... WARNING
Error: package/namespace load failed for ‘metaGSEA’
Call sequence:
2: stop(gettextf("package/namespace load failed for %s", sQuote(package)), 
  call. = FALSE, domain = NA)
1: library(package, lib.loc = lib.loc, character.only = TRUE, verbose = FALSE)
Execution halted

> sessionInfo()
R version 2.15.1 (2012-06-22)
Platform: x86_64-apple-darwin9.8.0/x86_64 (64-bit)

locale:
[1] en_AU.UTF-8/en_AU.UTF-8/en_AU.UTF-8/C/en_AU.UTF-8/en_AU.UTF-8

attached base packages:
[1] stats graphics  grDevices utils datasets  methods   base 
__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] R-2.15.1 CMD CHECK output: "Call Sequence"

2012-10-20 Thread Prof Brian Ripley

On Sat, 20 Oct 2012, Mark Cowley wrote:


Hi guRus,


i'm running R-2.15.1 and the R CMD CHECK output appears to have 
changed substantially, in that instead of pointing me to the


Changed since when?   This has been the behaviour for years with the 
error quoted.


offending functions or files, I get lots of 'call sequence' traces 
as below.


It is an offending _package_, and it tells you which one in


Error: package/namespace load failed for ‘metaGSEA’


Package 'metaGSEA' seems not to be installed properly.  It also tells 
you that 'library' is involved, so it looks like it is a package load 
and not a namespace load.


You have not told us if ‘metaGSEA’ is the package under test or a 
dependent.  Given that in earlier 'check' output which you excised the 
loading of the package under test was checked, the latter looks more 
plausible.


I've been using R CMD CHECK for years & never seen anything like 
this before. This is on a pretty fresh OSX 10.8 Mountain Lion 
installation, where I installed R from CRAN via pkg. Is this a 
problem unique to me?


Maybe not, but unusual.  It is a lot harder to get a package installed 
non-functionally these days, but it can happen if it were installed 
with a different version or architecture, or if binary packages are 
involved.




cheers,
Mark

heres' a snippet from testing one of my packages under development:

* checking for unstated dependencies in R code ... WARNING
Error: package/namespace load failed for ‘metaGSEA’
Call sequence:
2: stop(gettextf("package/namespace load failed for %s", sQuote(package)),
 call. = FALSE, domain = NA)
1: library(package, lib.loc = lib.loc, character.only = TRUE, verbose = FALSE)
Execution halted
See the information on DESCRIPTION files in the chapter ‘Creating R
packages’ of the ‘Writing R Extensions’ manual.
* checking S3 generic/method consistency ... WARNING
Error: package/namespace load failed for ‘metaGSEA’
Call sequence:
2: stop(gettextf("package/namespace load failed for %s", sQuote(package)),
 call. = FALSE, domain = NA)
1: library(package, lib.loc = lib.loc, character.only = TRUE, verbose = FALSE)
Execution halted
See section ‘Generic functions and methods’ of the ‘Writing R
Extensions’ manual.
* checking replacement functions ... WARNING
Error: package/namespace load failed for ‘metaGSEA’
Call sequence:
2: stop(gettextf("package/namespace load failed for %s", sQuote(package)),
 call. = FALSE, domain = NA)
1: library(package, lib.loc = lib.loc, character.only = TRUE, verbose = FALSE)
Execution halted
The argument of a replacement function which corresponds to the right
hand side must be named ‘value’.
* checking foreign function calls ... WARNING
Error: package/namespace load failed for ‘metaGSEA’
Call sequence:
2: stop(gettextf("package/namespace load failed for %s", sQuote(package)),
 call. = FALSE, domain = NA)
1: library(package, lib.loc = lib.loc, character.only = TRUE, verbose = FALSE)
Execution halted


sessionInfo()

R version 2.15.1 (2012-06-22)
Platform: x86_64-apple-darwin9.8.0/x86_64 (64-bit)

locale:
[1] en_AU.UTF-8/en_AU.UTF-8/en_AU.UTF-8/C/en_AU.UTF-8/en_AU.UTF-8

attached base packages:
[1] stats graphics  grDevices utils datasets  methods   base
__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel



--
Brian D. Ripley,  rip...@stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford, Tel:  +44 1865 272861 (self)
1 South Parks Road, +44 1865 272866 (PA)
Oxford OX1 3TG, UKFax:  +44 1865 272595__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Rcmd_environ and R_LIBS_{USER,SITE}

2012-10-20 Thread Uwe Ligges

Dirk,

if you are checking "foo", then "foo" is found in the examples (on all 
OSs), even if it is NOT installed at all!


Can you make the sources available for me?

Uwe







On 19.10.2012 23:58, Dirk Eddelbuettel wrote:


Hi Uwe,

On 19 October 2012 at 19:25, Uwe Ligges wrote:
| Dirk,
|
| if you ask R to
|
| R CMD check foo_1.2-3.tar.gz
|
|
| and the output is
|
| "no package called 'foo'"
|
| then something went wrong with your setup or your package.

That is not what I said, or tried to say. My issue is that the _tests_ and
_examples_ fail.

| Can we have details?

Sure -- See below.  Cut and pasted from an Emacs buffer on Windoze as
evidenved by the U:\ directory at mingw id shown. Emacs has no role here, it
also fails the same way in a normal DOS prompt.


u:\R\src>R CMD check foo_0.2.2.tar.gz
R CMD check foo_0.2.2.tar.gz
* using log directory 'u:/R/src/foo.Rcheck'
* using R version 2.15.1 (2012-06-22)
* using platform: x86_64-pc-mingw32 (64-bit)
* using session charset: ISO8859-1
* checking for file 'foo/DESCRIPTION' ... OK
* checking extension type ... Package
* this is package 'foo' version '0.2.2'
* 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 whether package 'foo' can be installed ... [34s] OK
* checking installed package size ... OK
* checking package directory ... OK
* checking for portable file names ... OK
* checking DESCRIPTION meta-information ... OK
* checking top-level 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
* loading checks for arch 'i386'
** 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
* loading checks for arch 'x64'
** 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 for unstated 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 ... OK
* checking Rd metadata ... OK
* checking Rd cross-references ... OK
* checking for missing documentation entries ... OK
* checking for code/documentation mismatches ... OK
* checking Rd \usage sections ... OK
* checking Rd contents ... OK
* checking for unstated dependencies in examples ... OK
* checking contents of 'data' directory ... OK
* checking data for non-ASCII characters ... OK
* checking data for ASCII and uncompressed saves ... OK
* checking line endings in C/C++/Fortran sources/headers ... OK
* checking line endings in Makefiles ... OK
* checking for portable compilation flags in Makevars ... OK
* checking for portable use of $(BLAS_LIBS) and $(LAPACK_LIBS) ... OK
* checking compiled code ... OK
* checking examples ...
** running examples for arch 'i386' ... ERROR
Running examples in 'foo-Ex.R' failed
The error occurred in:


R version 2.15.1 (2012-06-22) -- "Roasted Marshmallows"
Copyright (C) 2012 The R Foundation for Statistical Computing
ISBN 3-900051-07-0
Platform: i386-pc-mingw32/i386 (32-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

   Natural language support but running in an English locale

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.


pkgname <- "foo"
source(file.path(R.home("share"), "R", "examples-header.R"))
options(warn = 1)
options(pager = "console")
library('foo')

Error in library("foo") : there is no package called 'foo'
Execution halted
** running examples for arch 'x64' ... ERROR
Running examples in 'foo-Ex.R' failed
The error occurred in:


R version 2.15.1 (2012-06-22) -- "Roasted Marshmallows"
Copyright (C) 2012 The R Foundation for Statistical Computing
ISBN 3-900051-07-0
Platform: x86_64-pc-mingw32/x64 (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' f

Re: [Rd] Rcmd_environ and R_LIBS_{USER,SITE}

2012-10-20 Thread Dirk Eddelbuettel

Hi Uwe,

On 20 October 2012 at 16:57, Uwe Ligges wrote:
| Dirk,
| 
| if you are checking "foo", then "foo" is found in the examples (on all 
| OSs), even if it is NOT installed at all!

Well the log you asked me to supply very clearly shows otherwise.

All I doing is 

 i)  R itself in  c:\opt\R-current\ (currently 2.15.1)

 ii) packages in c:\opt\R-library\  (incl. the pkg in question)
 
| Can you make the sources available for me?

 a) It contains code from work code I cannot distribute.

 b) I will check next week about using a CRAN package. I suspect that, say,
my small-ish digest package will fail the same way.

 c) Having authored what must be around two dozen packages of which around
three quarters are actively maintained and on CRAN, I am reasonably
confident that I did nothing "wrong" here.

 d) Once I add '--no-tests --no-examples' then R CMD check passes fine. So
the package seems fine.

 e) No issues whatsoever on Linux. 

More on Monday or Tuesday. 

Thanks,  Dirk
 
| Uwe
| 
| 
| 
| 
| 
| 
| 
| On 19.10.2012 23:58, Dirk Eddelbuettel wrote:
| >
| > Hi Uwe,
| >
| > On 19 October 2012 at 19:25, Uwe Ligges wrote:
| > | Dirk,
| > |
| > | if you ask R to
| > |
| > | R CMD check foo_1.2-3.tar.gz
| > |
| > |
| > | and the output is
| > |
| > | "no package called 'foo'"
| > |
| > | then something went wrong with your setup or your package.
| >
| > That is not what I said, or tried to say. My issue is that the _tests_ and
| > _examples_ fail.
| >
| > | Can we have details?
| >
| > Sure -- See below.  Cut and pasted from an Emacs buffer on Windoze as
| > evidenved by the U:\ directory at mingw id shown. Emacs has no role here, it
| > also fails the same way in a normal DOS prompt.
| >
| >
| > u:\R\src>R CMD check foo_0.2.2.tar.gz
| > R CMD check foo_0.2.2.tar.gz
| > * using log directory 'u:/R/src/foo.Rcheck'
| > * using R version 2.15.1 (2012-06-22)
| > * using platform: x86_64-pc-mingw32 (64-bit)
| > * using session charset: ISO8859-1
| > * checking for file 'foo/DESCRIPTION' ... OK
| > * checking extension type ... Package
| > * this is package 'foo' version '0.2.2'
| > * 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 whether package 'foo' can be installed ... [34s] OK
| > * checking installed package size ... OK
| > * checking package directory ... OK
| > * checking for portable file names ... OK
| > * checking DESCRIPTION meta-information ... OK
| > * checking top-level 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
| > * loading checks for arch 'i386'
| > ** 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
| > * loading checks for arch 'x64'
| > ** 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 for unstated 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 ... OK
| > * checking Rd metadata ... OK
| > * checking Rd cross-references ... OK
| > * checking for missing documentation entries ... OK
| > * checking for code/documentation mismatches ... OK
| > * checking Rd \usage sections ... OK
| > * checking Rd contents ... OK
| > * checking for unstated dependencies in examples ... OK
| > * checking contents of 'data' directory ... OK
| > * checking data for non-ASCII characters ... OK
| > * checking data for ASCII and uncompressed saves ... OK
| > * checking line endings in C/C++/Fortran sources/headers ... OK
| > * checking line endings in Makefiles ... OK
| > * checking for portable compilation flags in Makevars ... OK
| > * checking for portable use of $(BLAS_LIBS) and $(LAPACK_LIBS) ... OK
| > * checking compiled code ... OK
| > * checking examples ...
| > ** running examples for arch 'i386' ... ERROR
| > Running examples in 'foo-Ex.R' failed
| > The error occurred in:
| >
| >
| > R version 2.15.1 (2012-06-22) -- "Roasted Marshmallows"
| > Copyright (C) 2012 The R Foundation for Statistical Computing
| > ISBN 3-900051

Re: [Rd] Change in the RNG implementation?

2012-10-20 Thread Martin Maechler
> Duncan Murdoch 
> on Fri, 19 Oct 2012 19:26:39 -0400 writes:

> On 12-10-19 7:04 PM, Hervé Pagès wrote:
>> Hi,
>> 
>> Looks like the implementation of random number generation changed in
>> R-devel with respect to R-2.15.1.
>> 
>> With R-2.15.1:
>> 
>> > set.seed(33)
>> > sample(49821115, 10)
>> [1] 22217252 19661919 24099911 45779422 42043111 25774933 21778053
>> 17098516
>> [9]   773073  5878451
>> 
>> With recent R-devel:
>> 
>> > set.seed(33)
>> > sample(49821115, 10)
>> [1] 22217252 19661919 24099912 45779425 42043115 25774935 21778056
>> 17098518
>> [9]   773073  5878452
>> 
>> This is on a 64-bit Ubuntu system.
>> 
>> Is this change intended? I didn't see anything in the NEWS file.
>> 
>> A potential problem with this is that it will break unit tests
>> for algorithms that make use of RNG.
>> 
>> Another more practical problem (at least for me) is the following:
>> Bioconductor package maintainers are sometimes working hard on the
>> development version of their package to improve the performance of
>> some key functions. Comparing performance between BioC release
>> (based on R-2.15) and devel (based on R-devel) often requires big
>> input data that is randomly generated, because it's easiest than
>> working with real data. Typically a small script is written that
>> takes care of loading the required packages, generating the input
>> data, and running a simple analysis. The same script is sourced in
>> R-2.15 and R-devel, and performance and results are compared.
>> 
>> Not being able to generate exactly the same input in the script is
>> a problem. It can be worked around by generating the input once,
>> serializing it, and use load() in the script, but that makes things
>> more complicated and the script is not a standalone script anymore
>> (cannot be passed around without also passing around the big .rda
>> file).
>> 
>> Thanks,
>> H.
>> 

> I think it was mentioned in the NEWS:

> \code{sample.int()} has some support for  \eqn{n \ge
> 2^{31}}{n >= 2^31}: see its help for the limitations.

> A different algorithm is used for \code{(n, size, replace = FALSE,
> prob = NULL)} for \code{n > 1e7} and \code{size <= n/2}.  This
> is much faster and uses less memory, but does give different results.

So, to iterate : The  RNG  has not been changed at all,
but  sample() has, for extreme cases (large n) like yours.

> I don't think the old algorithm is available, but perhaps it could be 
> made available by an optional parameter.

I do think we should ideally add such an option or probably
rather allow the more thorough way of either using  
RNGversion(..) or something similar to set sample()'s behavior
to exactly as previously.
Doing "globally" is really needed, as sample() maybe called from a
function (from a function from a function) that is not in the
programmer's hand, and so the programmeR could not even
set the new optional argument if he found out that he had to.

Honestly, I'm surprised Hervé found a real case where the
difference is visible.

Martin


> Duncan Murdoch

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel