Problem using biocLite() to update packages
1
0
Entering edit mode
Jenny Drnevich ★ 2.0k
@jenny-drnevich-2812
Last seen 5 months ago
United States

Hi all,

I've had a weird thing happen occasionally in the past when using biocLite() to update packages and it just happened again and I finally had time to ask about it. I had upgraded everything to BioC 3.6 last week with no trouble. I just noticed today that the orgDB packages didn't get updated until this week, so I went to update as normal, opening a fresh session of R:

R version 3.4.2 (2017-09-28) -- "Short Summer"
Copyright (C) 2017 The R Foundation for Statistical Computing
Platform: x86_64-w64-mingw32/x64 (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> source("https://bioconductor.org/biocLite.R")
Bioconductor version 3.6 (BiocInstaller 1.28.0), ?biocLite for help
> biocLite()
BioC_mirror: https://bioconductor.org
Using Bioconductor 3.6 (BiocInstaller 1.28.0), R 3.4.2 (2017-09-28).
installation path not writeable, unable to update packages: mgcv
Old packages: 'AnnotationHub', 'ComplexHeatmap', 'DelayedArray', 'devtools', 'GEOquery', 'GO.db', 'lubridate', 'methylumi', 'openssl',
  'org.At.tair.db', 'org.Bt.eg.db', 'org.Hs.eg.db', 'org.Mm.eg.db', 'org.Rn.eg.db', 'org.Sc.sgd.db', 'org.Ss.eg.db', 'org.Xl.eg.db', 'pdftools',
  'PFAM.db', 'phyloseq', 'R.utils', 'rlang', 'rmarkdown', 'tidyselect', 'tidyverse', 'VariantAnnotation'
Update all/some/none? [a/s/n]: 
a

It then proceeds to download and unpack the packages as normal but then I start running into some errors:

package ‘callr’ successfully unpacked and MD5 sums checked
package ‘clipr’ successfully unpacked and MD5 sums checked
package ‘cli’ successfully unpacked and MD5 sums checked
package ‘dbplyr’ successfully unpacked and MD5 sums checked
package ‘reprex’ successfully unpacked and MD5 sums checked
package ‘AnnotationHub’ successfully unpacked and MD5 sums checked
package ‘ComplexHeatmap’ successfully unpacked and MD5 sums checked
package ‘DelayedArray’ successfully unpacked and MD5 sums checked
package ‘devtools’ successfully unpacked and MD5 sums checked
package ‘lubridate’ successfully unpacked and MD5 sums checked
package ‘methylumi’ successfully unpacked and MD5 sums checked
package ‘openssl’ successfully unpacked and MD5 sums checked
package ‘pdftools’ successfully unpacked and MD5 sums checked
package ‘phyloseq’ successfully unpacked and MD5 sums checked
package ‘R.utils’ successfully unpacked and MD5 sums checked
package ‘rlang’ successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package ‘rlang’
package ‘rmarkdown’ successfully unpacked and MD5 sums checked
package ‘tidyselect’ successfully unpacked and MD5 sums checked
package ‘tidyverse’ successfully unpacked and MD5 sums checked
package ‘VariantAnnotation’ successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package ‘VariantAnnotation’

Note the warning about not being able to remove prior packages of rlang and VariantAnnotation. I know rlang is CRAN, but VariantAnnotation is BioC and besides, it's been different packages the other times this has happened. I've learned my lesson to not have any other R sessions open or any packages loaded when trying to install or upgrade, so that's not the cause of the problem. The problem snowball from here:

* installing *source* package 'GEOquery' ...
** R
** inst
** preparing package for lazy loading
Error in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]) : 
  there is no package called 'rlang'
ERROR: lazy loading failed for package 'GEOquery'
* removing 'C:/Users/drnevich/Documents/R/win-library/3.4/GEOquery'
* restoring previous 'C:/Users/drnevich/Documents/R/win-library/3.4/GEOquery'
* installing *source* package 'GO.db' ...
** R
** inst
** preparing package for lazy loading
Error: package or namespace load failed for 'AnnotationDbi' in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]):
 there is no package called 'rlang'
Error : package 'AnnotationDbi' could not be loaded
ERROR: lazy loading failed for package 'GO.db'
* removing 'C:/Users/drnevich/Documents/R/win-library/3.4/GO.db'
* restoring previous 'C:/Users/drnevich/Documents/R/win-library/3.4/GO.db'

And so on for all the orgDB packages I'm trying to upgrade. It ends with:

The downloaded source packages are in
‘C:\Users\drnevich\AppData\Local\Temp\RtmpCuYahq\downloaded_packages’
There were 22 warnings (use warnings() to see them)

> warnings()[1:4]
Warning messages:
1: running command '"C:/PROGRA~1/R/R-34~1.2/bin/x64/R" CMD INSTALL -l "C:\Users\drnevich\Documents\R\win-library\3.4" C:\Users\drnevich\AppData\Local\Temp\RtmpCuYahq/downloaded_packages/GEOquery_2.46.3.tar.gz' had status 1
2: In install.packages(update[instlib == l, "Package"], l,  ... :
  installation of package ‘GEOquery’ had non-zero exit status
3: running command '"C:/PROGRA~1/R/R-34~1.2/bin/x64/R" CMD INSTALL -l "C:\Users\drnevich\Documents\R\win-library\3.4" C:\Users\drnevich\AppData\Local\Temp\RtmpCuYahq/downloaded_packages/GO.db_3.5.0.tar.gz' had status 1
4: In install.packages(update[instlib == l, "Package"], l,  ... :
  installation of package ‘GO.db’ had non-zero exit status

I don't have any packages loaded and even though there is an rlang folder in my library, it fails to load and causes subsequent packages to fail to load:

> sessionInfo()
R version 3.4.2 (2017-09-28)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows >= 8 x64 (build 9200)

Matrix products: default

locale:
[1] LC_COLLATE=English_United States.1252  LC_CTYPE=English_United States.1252    LC_MONETARY=English_United States.1252
[4] LC_NUMERIC=C                           LC_TIME=English_United States.1252    

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] BiocInstaller_1.28.0

loaded via a namespace (and not attached):
[1] compiler_3.4.2 tools_3.4.2    yaml_2.1.14   
> .libPaths()
[1] "C:/Users/drnevich/Documents/R/win-library/3.4" "C:/Program Files/R/R-3.4.2/library"           
> dir(path = .libPaths()[1], pattern = "rlang")
[1] "rlang"
> library(rlang)
Error in library(rlang) : there is no package called ‘rlang’
> library(VariantAnnotation)
Error in library(VariantAnnotation) : 
  there is no package called ‘VariantAnnotation’
> library(PFAM.db)
Loading required package: AnnotationDbi
#trimmed output to save space...

Error: package or namespace load failed for ‘AnnotationDbi’ in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]):
 there is no package called ‘rlang’
Error: package ‘AnnotationDbi’ could not be loaded

What I have done to fix the problem is to manually delete the rlang and VariantAnnotation folders, restart R, install these two packages using biocLite, then update everything else. Sometimes this leads to finding other packages that had gotten corrupted. I just had my officemate try to upgrade and he had no trouble. He suggested that maybe my backup system (Crashplan) might have been accessing those folders at the time and that's what caused the problem. That kind of makes sense... do you agree or have any other suggestions? I can fix it when it happens, it's just frustrating and seemingly random!

Thanks

 

biocLite BiocInstaller variantannotation • 3.0k views
ADD COMMENT
0
Entering edit mode
@james-w-macdonald-5106
Last seen 10 hours ago
United States

One of the issues with Windows is that you lock any dir that is being accessed, like in any way, by any process. As an example:

> .libPaths()
[1] "C:/Users/jmacdon/AppData/Roaming/R/win-library/3.4"
[2] "c:/Program Files/R/R-3.4.1/library"

Now I open a command prompt and do this:

C:\Users\jmacdon> cd AppData\Roaming\R\win-library\3.4\gcrma

C:\Users\jmacdon\AppData\Roaming\R\win-library\3.4\gcrma>

So now I have this directory 'opened' in a command prompt window. Let's try to update gcrma, shall we?

> biocLite("gcrma")
BioC_mirror: https://bioconductor.org
Using Bioconductor 3.5 (BiocInstaller 1.26.1), R 3.4.1 (2017-06-30).
Installing package(s) 'gcrma'
trying URL 'https://bioconductor.org/packages/3.5/bioc/bin/windows/contrib/3.4/gcrma_2.48.0.zip'
Content type 'application/zip' length 493850 bytes (482 KB)
downloaded 482 KB

package 'gcrma' successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package 'gcrma'

Et voila! Stupid Windows.

ADD COMMENT
0
Entering edit mode
Yep, stupid Windows! That must be the cause of the random packages not being able to update. I’ll try to remember to shut down my CrashPlan before updating in the future. Cheers, From: James W. MacDonald [bioc] [mailto:noreply@bioconductor.org] Sent: Friday, November 10, 2017 4:20 PM To: Zadeh, Jenny Drnevich <drnevich@illinois.edu> Subject: [bioc] A: Problem using biocLite() to update packages Activity on a post you are following on support.bioconductor.org<https: support.bioconductor.org=""> User James W. MacDonald<https: support.bioconductor.org="" u="" 5106=""/> wrote Answer: Problem using biocLite() to update packages<https: support.bioconductor.org="" p="" 102878="" #102879="">: One of the issues with Windows is that you lock any dir that is being accessed, like in any way, by any process. As an example: > .libPaths() [1] "C:/Users/jmacdon/AppData/Roaming/R/win-library/3.4" [2] "c:/Program Files/R/R-3.4.1/library" Now I open a command prompt and do this: C:\Users\jmacdon> cd AppData\Roaming\R\win-library\3.4\gcrma C:\Users\jmacdon\AppData\Roaming\R\win-library\3.4\gcrma> So now I have this directory 'opened' in a command prompt window. Let's try to update gcrma, shall we? > biocLite("gcrma") BioC_mirror: https://bioconductor.org Using Bioconductor 3.5 (BiocInstaller 1.26.1), R 3.4.1 (2017-06-30). Installing package(s) 'gcrma' trying URL 'https://bioconductor.org/packages/3.5/bioc/bin/windows/contrib/3.4/gcrma_2.48.0.zip' Content type 'application/zip' length 493850 bytes (482 KB) downloaded 482 KB package 'gcrma' successfully unpacked and MD5 sums checked Warning: cannot remove prior installation of package 'gcrma' Et voila! Stupid Windows. ________________________________ Post tags: biocLite, BiocInstaller, variantannotation You may reply via email or visit A: Problem using biocLite() to update packages
ADD REPLY

Login before adding your answer.

Traffic: 623 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6