Question: errors in namespaceExports during biocLite installs
gravatar for shabbychef
3.9 years ago by
United States
shabbychef0 wrote:

I am apparently unable to use biocLite to install any packages. A typical attempt goes as follows:

sudo R --quiet --vanilla

> sessionInfo()
R version 3.1.3 (2015-03-09)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 14.04.2 LTS

 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C              
 [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8    
 [7] LC_PAPER=en_US.UTF-8       LC_NAME=C                 
 [9] LC_ADDRESS=C               LC_TELEPHONE=C            

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     
> source("")
Bioconductor version 3.0 (BiocInstaller 1.16.2), ?biocLite for help
> biocLite('graph')
Using Bioconductor version 3.0 (BiocInstaller 1.16.2), R version 3.1.3.
Installing package(s) 'graph'
trying URL ''
Content type 'application/x-gzip' length 961739 bytes (939 KB)
opened URL
downloaded 939 KB

* installing *source* package ‘graph’ ...
** libs
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG      -fpic  -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -D_FORTIFY_SOURCE=2 -g  -c graph.c -o graph.o
gcc -std=gnu99 -shared -L/usr/lib/R/lib -Wl,-Bsymbolic-functions -Wl,-z,relro -o graph.o -L/usr/lib/R/lib -lR
installing to /home/spav/R/x86_64-pc-linux-gnu-library/3.1/graph/libs
** R
** data
** inst
** preparing package for lazy loading
Error in namespaceExport(ns, exports) : 
  undefined exports: .__C__file, .__C__pipe, .__C__textConnection, .__C__AsIs
ERROR: lazy loading failed for package ‘graph’
* removing ‘/home/spav/R/x86_64-pc-linux-gnu-library/3.1/graph’


I get the same error every time: Error in namespaceExports, and so on. I have tried using useDevel, but 'devel' version requires a more recent R (than 3.1.3?)

biocinstaller installation • 1.1k views
ADD COMMENTlink written 3.9 years ago by shabbychef0

Maybe try biocValid() and do what it suggests? And/or run biocLite() without arguments to update all your packages.

ADD REPLYlink written 3.9 years ago by Dan Tenenbaum8.2k

calling biocValid() suggested I downgrade some packages. I politely declined. The solution I found was to install BiocGenerics as noted in my comment.

ADD REPLYlink written 3.9 years ago by shabbychef0

When biocValid() says to downgrade packages, it means those packages were not installed via biocLite() and maybe they are from the devel version of Bioconductor (or from Github or some other repository besides Bioconductor and CRAN).

This is good advice; packages from devel are not meant to run in the release version of Bioconductor, and vice versa.

graph imports BiocGenerics, so running biocLite("graph") should install BiocGenerics; my guess is you had a "too new" version of BiocGenerics and that biocLite("BiocGenerics") fixed this. So, in a roundabout way you (partially) followed the advice that biocValid() gave.


ADD REPLYlink written 3.9 years ago by Dan Tenenbaum8.2k

Actually, my goal was to simply install the graph package, not to use Bioconductor per se. For this reason, I did not want to downgrade packages (which could potentially have side effects). My attempts to use the Bioconductor repository as a CRAN replacement and simply install via install.packages gave the same result. Again, I am unable to replicate the problem elsewhere than on my laptop, and have fixed it there by installing BiocGenerics. I'll just leave the Q here in case someone else stumbles on the same problem.

ADD REPLYlink written 3.9 years ago by shabbychef0

biocValid() will only tell you to downgrade Bioonductor packages, not any other packages you may have installed. Following its advice would also have fixed your problem.

ADD REPLYlink written 3.9 years ago by Dan Tenenbaum8.2k

In that regard, it utterly failed, as it suggested downgrading packages before I had ever installed anything from Bioconductor, including packages I had installed from github via devtools. For example, the 'syuzhet' package.

ADD REPLYlink written 3.9 years ago by shabbychef0

biocValid() actually reports packages whose version differs from the version in CRAN or Bioc; I guess you've installed syuzhet from a github repository and that the github version is newer than the one in CRAN. This to me makes a lot of sense -- you're using biocValid() because you're having problems with your installation, and this is one way your installation differs from expectation. Your response (no, I don't want to downgrade) also seems completely appropriate.

It remains a mystery why biocValid() apparently didn't say that BiocGenerics was different from expected (or did it?). It also seems most likely that the problem was a too _old_ version of BiocGenerics, and then install.packages / biocLite() should normally have updated it before installing graph. Also, 'too old' is really quite old, the code was added to BiocGenerics in at least Nov 19, 2011. Maybe a more plausible scenario is that the BiocGenerics installation was corrupted in some other way. But I guess your system is back in order now so there is no further way to explore this.

ADD REPLYlink written 3.9 years ago by Martin Morgan ♦♦ 23k

Poking around in the graph package's DESCRIPTION file, the Import of BiocGenerics looked out of place. So I issued the following:


After that, a call to biocLite('graph') appears to install the package properly... 

ADD REPLYlink written 3.9 years ago by shabbychef0

This error occurred on my laptop, running 3.1.3 on Ubuntu 14.04. I am unable to replicate it on 3.1.3 under Ubuntu 12.04, or 3.1.3 under Debian 8 in rocker/r-devel. So there is something idiosyncratic and weird about my laptop.

ADD REPLYlink written 3.9 years ago by shabbychef0
Please log in to add an answer.


Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 16.09
Traffic: 442 users visited in the last hour