Cannot install packages by BiocManager::install()
1
5
Entering edit mode
mizzle ▴ 50
@91208a6c
Last seen 5 weeks ago
United States

Recently I updated my R from 3.6.3 to 4.0.5. I can install packages by BiocManager::install() while I was using R 3.6.3. However, I cannot install packages by BiocManager::install() while I am using R 4.0.5. I can install packages such as ggplot2 by install.packages("ggplot2") in R 4.0.5. I don't know why BiocManager::install() didn't work in my computer for R 4.0.5. Please see the error message below. Thank you!

> if (!requireNamespace("BiocManager", quietly = TRUE))
+     install.packages("BiocManager")
>
> BiocManager::install("sva")
'getOption("repos")' replaces Bioconductor standard repositories, see '?repositories' for details

replacement repositories:
CRAN: https://cran.rstudio.com/

Bioconductor version 3.12 (BiocManager 1.30.13), R 4.0.5 (2021-03-31)
Installing package(s) 'BiocVersion', 'sva'
also installing the dependency ‘genefilter’


BiocManager • 1.5k views
1
Entering edit mode

I am having the same issue and have tried reinstalling R multiple times (4.0.5 and 3.6.3) and have consistently ran into this issue. I specifically had the issue when trying to install BSgenome, but have also found that I can't install IRanges anymore even though I was able to install that package a few days ago without any errors.

4
Entering edit mode

A problem has been identified in BiocManager 1.30.13. Please do the following:

install.packages("devtools")   # unnecessary if you have it already
devtools::install_github("Bioconductor/BiocManager", ref="ghost-binary-repo")


now use BiocManager in the customary way. Let us know how it goes.

0
Entering edit mode

This fixed my issue. Thanks so much!

0
Entering edit mode

Hi I am still having the same issue after running your above suggestion. Any thoughts? I just upgraded to R 4.0.5 on a Mac M1

BiocManager::install("phyloseq") 'getOption("repos")' replaces Bioconductor standard repositories, see '?repositories' for details

replacement repositories: CRAN: https://cran.rstudio.com/

Bioconductor version 3.12 (BiocManager 1.30.13), R 4.0.5 (2021-03-31) Installing package(s) 'phyloseq' also installing the dependencies ‘hms’, ‘Rhdf5lib’, ‘rhdf5filters’, ‘zlibbioc’, ‘pixmap’, ‘sp’, ‘progress’, ‘rhdf5’, ‘S4Vectors’, ‘IRanges’, ‘XVector’, ‘iterators’, ‘ade4’, ‘ape’, ‘Biobase’, ‘BiocGenerics’, ‘biomformat’, ‘Biostrings’, ‘data.table’, ‘foreach’, ‘igraph’, ‘multtest’, ‘plyr’, ‘reshape2’

0
Entering edit mode

Hi Rachel -- you will have to restart R. You need to see BiocManager 1.30.13.1 -- in the above I only see 1.30.13, so try again with devtools::install_github("Bioconductor/BiocManager", ref="ghost-binary-repo") and then start R again and try the phyloseq installation

0
Entering edit mode

It helps! Thank you!

0
Entering edit mode

Thank you very much, it works, I was loosing my mind already.

0
Entering edit mode

On executing the above code:

devtools::install_github("Bioconductor/BiocManager", ref="ghost-binary-repo")


I get the following error: WARNING: Rtools is required to build R packages, but is not currently installed.

0
Entering edit mode

I restarted the R. I ran R as administrator. I choose another mirror. While the error is still there. I have another computer. I also updated the R from 3.6.3 to 4.0.5. The R version, mirror, the location of the R library are all the same between the two computers. However, the other computer didn't have this error.

0
Entering edit mode

Thanks so much for posting this! Have been going crazy all afternoon trying to install a package!

0
Entering edit mode
@d27aed9d
Last seen 9 days ago
Germany

Hi, I'm having the same issue with GeneAnswers and KEGG.db. I tried to run devtools::install_github("Bioconductor/BiocManager", ref="ghost-binary-repo") but I get following error

Error in utils::download.file(url, path, method = method, quiet = quiet, : URL 'https://api.github.com/repos/Bioconductor/BiocManager/tarball/ghost-binary-repo'

any help? Thanks

0
Entering edit mode

Installing that specific version of BiocManager via Github was a temporary work around to make the fix available immediately, because it take a while for a new version to become available from CRAN.

You should be fine to use the version that is now installed with install.packages("BiocManager").

0
Entering edit mode

I also have the same issue. I currently have Bioconductor version 3.13 (BiocManager 1.30.15), R 4.1.0 (2021-05-18) . and the similar error occurs. With other biocmanager installation, the error said

'getOption("repos")' replaces Bioconductor standard repositories, see '?repositories' for
details


Does somebody has any ideas how should I fix this?

0
Entering edit mode

Did you re-install BiocManager as Mike recommended?