[Bioc-devel] How to recreate R CMD BUILD environment in interactive session?

Elizabeth Purdom epurdom at stat.berkeley.edu
Mon Oct 23 15:59:08 CEST 2017

> On Oct 23, 2017, at 3:47 PM, Martin Morgan <martin.morgan at roswellpark.org> wrote:
> On 10/23/2017 09:26 AM, Elizabeth Purdom wrote:
>> Hello,
>> I am updating an existing package and I am getting an error in running my vignette (and a similar error in an example in help pages) but ONLY when I run R CMD BUILD. I can’t recreate the error in any session where I can debug and figure out what is happening. So my question is how can I recreate the exact environment of R CMD BUILD that runs the vignette but in an interactive session so that I can figure out what is going on?
>> I have tried reproducing the error in other environments:
>> * Running R —vanilla interactively and trying the code manually
>> * running purl on my vignette to get pure R code and running just the R code with R CMD BATCH —vanilla
> hint on the specific package and / or error message?
> My approach would be to install the package, Stangle / purl the vignette, and R -f vignette.R, then trim the vignette to a fast reproducible case. But it sounds like you're doing that...
> Martin

Yes, that is what I tried but did not get the error from the R code. 

And I apologize, it’s the `clusterExperiment` package. My error was so specific to the class created by my package that I didn’t think it would be useful, but here is the relevant error message:

Quitting from lines 271-272 (clusterExperimentTutorial.Rmd) 
Error: processing vignette 'clusterExperimentTutorial.Rmd' failed with diagnostics:
invalid class "ClusterExperiment" object: merge_nodeMerge must have 4 columns and column names equal to: 'Node','Contrast','isMerged','mergeClusterId'
Execution halted

I would note that my vignette calls an object that is saved as a data object as part of my package to speed up compilation. But I experimented and you can also switch it so that it creates the object from scratch and doesn’t load the object, and it runs into the same error. There is a `LazyData: false` in my DESCRIPTION File, because I was having problems with my R data object, because it is of the class I make with my package, and without the package loaded there was some problem loading it. 

	[[alternative HTML version deleted]]

More information about the Bioc-devel mailing list