[Bioc-devel] avoiding circular dependencies between a Data package and a Software package

Tim Triche, Jr. tim@triche @ending from gm@il@com
Sat Oct 6 19:40:38 CEST 2018


Last night I submitted MTseeker and its companion package MTseekerData,
both festooned with examples that run smoothly and pass BiocCheck.

HOWEVER! Breaking up the data into a Data package inadvertently seems to
have created a circular dependency between the Software and Data packages.
I haven't had to deal with this in the past, and mostly sidestepped it by
skipping a Depends: entry in Data.

(cf. https://support.bioconductor.org/p/113711 , which I will update with
answers from here to try and avoid having other people with the same
problem bug youse plural)

The issue seems to be that, since the MTseeker-defined MVRanges and
MAlignments classes (which, as you might imagine, subclass the VRanges and
GAlignments classes) hold the data stored in MTseekerData, the examples in
MTseekerData call the `show` method (and others) on the objects and this
create issues.  The most bizarre of these complained at installation about
(sp?) .lazyLoadCacheManager() (I'm having trouble reproducing this exact
error but it was memorable).  Does this ring a bell for anyone? Is there an
elegant workaround?

I can't imagine I'm the first person to have this issue.  I know there are
also various automagic hooks in BioC to load a package upon discovering a
data structure that belongs to it (and not before) -- should I be using
attachNamespace() somehow to side-step this problem?  (Eventually I do want
to submit BAM files to ExperimentHub for an end-to-end example and unit
tests, but the more pressing issue here was BiocCheck).

Any feedback is much appreciated. It's kind of a drag when all the examples
and vignettes pass and build, but only with a side-stepping of
dependencies. That can't possibly be the correct solution, yet I'm at a
loss to find documentation (which I'm sure exists somewhere) that explains
how to avoid this (and/or implement the hooks).

Thank you,

--t

	[[alternative HTML version deleted]]



More information about the Bioc-devel mailing list