Re: [Rd] --as-cran error

From: Duncan Murdoch <murdoch.duncan_at_gmail.com>
Date: Wed, 02 May 2012 07:27:16 -0400

On 12-05-02 6:06 AM, Mauricio Zambrano-Bigiarini wrote:
> Dear List,
>
> While using the --as-cran option for checking one of my packages:
>
> R CMD check --as-cran hydroGOF_0.3-3.tar.gz
>
>
> I got the following error message:
>
> pkgname<- "hydroGOF"
> > source(file.path(R.home("share"), "R", "examples-header.R"))
> > options(warn = 1)
> > library('hydroGOF')
> Error in loadNamespace(i[[1L]], c(lib.loc, .libPaths())) :
> there is no package called ‘class’
>
> However, I don't get any error message when the checking is done without
> the --as-cran option.
>
> Could somebody give me a hint about how to solve this error before
> submission to CRAN ?

There was a bug in 2.15.0: if your package used a package that used a recommended package (where "used" means listed as Depends, Suggests, Imports...), then you could get this error.

R-patched has this fixed, so you could update to that. If you don't want to update, the workaround is to list "class" explicitly as a dependency of your package.

Duncan Murdoch

>
>
> sessionInfo()
> R version 2.15.0 (2012-03-30)
> Platform: x86_64-redhat-linux-gnu (64-bit)
>
> locale:
> [1] LC_CTYPE=en_GB.utf8 LC_NUMERIC=C
> [3] LC_TIME=en_GB.utf8 LC_COLLATE=en_GB.utf8
> [5] LC_MONETARY=en_GB.utf8 LC_MESSAGES=en_GB.utf8
> [7] LC_PAPER=C LC_NAME=C
> [9] LC_ADDRESS=C LC_TELEPHONE=C
> [11] LC_MEASUREMENT=en_GB.utf8 LC_IDENTIFICATION=C
>
> attached base packages:
> [1] stats graphics grDevices utils datasets methods base
>
>
> Thanks in advance,
>
> Mauricio Zambrano-Bigiarini



R-devel_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel Received on Wed 02 May 2012 - 11:30:05 GMT

This quarter's messages: by month, or sorted: [ by date ] [ by thread ] [ by subject ] [ by author ]

All messages

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Wed 02 May 2012 - 15:30:52 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-devel. Please read the posting guide before posting to the list.

list of date sections of archive