pak icon indicating copy to clipboard operation
pak copied to clipboard

when Bioconductor is inaccessible, pak::repo_status(bioc = FALSE) gives error

Open tyner opened this issue 2 months ago • 1 comments

Similar to #726, on a machine where Bioconductor is inaccessible, and using version 0.9.0 of pak

pak::repo_status(bioc = FALSE)

gives

Error: 
! error in pak subprocess
Caused by error in `download.file(url, tmp, quiet = TRUE)`:
! cannot open URL 'http://bioconductor.org/config.yaml'
Type .Last.error to see the more details.

and .Last.error says

<callr_error/rlib_error_3_0/rlib_error/error>
Error: 
! error in pak subprocess
Caused by error in `download.file(url, tmp, quiet = TRUE)`:
! cannot open URL 'http://bioconductor.org/config.yaml'
---
Backtrace:
1. pak::repo_status(bioc = FALSE)
2. pak:::remote(function(...) asNamespace("pak")$repo_status_internal(...), …
3. err$throw(res$error)
---
Subprocess backtrace:
 1. base::withCallingHandlers(cli_message = function(msg) { …
 2. asNamespace("pak")$repo_status_internal(...)
 3. pkgcache::repo_status(platforms = platforms, r_version = r_version, …
 4. pkgcache:::synchronise(async_repo_status(platforms, r_version, bioc, cran_mirror))
 5. pkgcache:::async_repo_status(platforms, r_version, bioc, cran_mirror)
 6. pkgcache:::cmc__get_repos(getOption("repos"), bioc, cran_mirror, r_version)
 7. bioconductor$get_repos()
 8. local get_bioc_version(getRversion(), forget)
 9. local get_matching_bioc_version(r_version, forget = forget)
10. local get_version_map(forget = forget)
11. local get_yaml_config(forget)
12. base::stop(new)
13. global (function (e) …

I tried setting these but got the same result.

options(pkg.use_bioconductor = FALSE)
Sys.setenv(PKG_USE_BIOCONDUCTOR = "FALSE")

Thank you for considering.

tyner avatar Oct 10 '25 12:10 tyner

I’m facing the same issue, which prevents me from installing any package, even after trying to disable Bioconductor:

> pak::pkg_install("testthat")
Error: 
! error in pak subprocess
Caused by error in `download.file(url, tmp, quiet = TRUE)`:
! cannot open URL 'http://bioconductor.org/config.yaml'
Type .Last.error to see the more details.

Did you find a solution?

NLFVAL1 avatar Nov 11 '25 15:11 NLFVAL1