Re: [Rd] changes in recent R-devel revisions?

From: Martin Morgan <mtmorgan_at_fhcrc.org>
Date: Tue, 01 Mar 2011 19:36:47 -0800

On 03/01/2011 03:19 PM, Benilton Carvalho wrote:
> Hi,
>

> I have a BioC infra-structure package that works fine (I can build,
> check and load it successfully) on revision r53950. The very same
> package fails on r54591 with the error below:
>
> Error in loadNamespace(package, c(which.lib.loc, lib.loc), keep.source
> = keep.source) :
> cyclic name space dependency detected when loading ‘oligoClasses’,
> already loading ‘oligoClasses’
>
> I don't see anything obvious in the name space that would indicate
> cyclic dependency and I wonder:

For what it's worth, saying

> trace(stop, recover)

prior to library(oligoClasses) leads to

 7: loadNamespace(package, c(which.lib.loc, lib.loc), keep.source = keep.source

 8: methods:::cacheMetaData(ns, TRUE, ns)
 9: getGeneric(f, FALSE, searchWhere, fpkg)
10: tryCatch(loadNamespace(package), error = function(e) e)

where 'package' is oligoClasses in lines 7 and 10, and the 'f' in 9 is 'relocateObject'. Line 10 is evaluated when methods:::.getGeneric returns NULL.

In oligoClasses we have

oligoClasses/R> grep relocateObject *
AllGenerics.R:setGeneric("relocateObject", function(object, ...) standardGeneric("relocateObject"))
methods-CNSet.R:relocateObject <- function(object, to){

which I guess is not as intended.

My guess is that setGeneric adds the generic to a cache of some sort when the name space is created, but doesn't remove it when the generic is overwritten by a plain function.

No idea why this shows up in the current R revision.

Martin

>
> a) if there were changes that were meant to affect this;
>
> b) what is the recommended strategy to solve this issue.
>
> Thank you very much for any suggestion,
>
> benilton
>
> ______________________________________________
> R-devel_at_r-project.org mailing list
>
https://stat.ethz.ch/mailman/listinfo/r-devel

-- 
Computational Biology
Fred Hutchinson Cancer Research Center
1100 Fairview Ave. N. PO Box 19024 Seattle, WA 98109

Location: M1-B861
Telephone: 206 667-2793

______________________________________________
R-devel_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel
Received on Wed 02 Mar 2011 - 03:44:03 GMT

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 Mar 2011 - 07:10:26 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