Open MiguelRodo opened 7 months ago
Here's the message when booting up R
for the first time, and initialising the renv
lockfile with pak
enabled:
# Bootstrapping renv 1.0.5 ---------------------------------------------------
- Downloading renv ... OK
- Installing renv ... OK
ℹ Using R 4.4.0 (lockfile was generated with R 4.3.3)
# Downloading packages -------------------------------------------------------
- Downloading pak from r-lib ... OK [file is up to date]
Successfully downloaded 1 package in 1 second.
The following package(s) will be installed:
- pak [0.7.2]
These packages will be installed into "/workspaces/.local/.cache/R/renv/R-4.4/x86_64-pc-linux-gnu".
Do you want to proceed? [Y/n]: Y
# Installing packages --------------------------------------------------------
- Installing pak ... OK [installed binary and cached in 1.6s]
Successfully installed 1 package in 1.8 seconds.
Error in remote(function(...) get("pkg_install_make_plan", asNamespace("pak"))(...), :
Subprocess is busy or cannot start
Traceback (most recent calls last):
21: source("renv/activate.R")
20: withVisible(eval(ei, envir))
19: eval(ei, envir)
18: eval(ei, envir)
17: local(...) at activate.R#2
16: eval.parent(substitute(eval(quote(expr), envir)))
15: eval(expr, p)
14: eval(expr, p)
13: eval(quote(...), new.env())
12: eval(quote(...), new.env())
11: renv_bootstrap_exec(project, libpath, version) at activate.R#1197
10: if (!renv_bootstrap_load(project, libpath, version))
renv_bootstrap_run(version, libpath) at activate.R#1030
9: return(renv::load(project = getwd())) at activate.R#1045
8: renv_load_bioconductor(project, lockfile$Bioconductor)
7: renv_bioconductor_init()
6: renv_bioconductor_init_biocmanager(library)
5: install("BiocManager", library = library, prompt = FALSE)
4: renv_pak_install(packages, libpaths, project)
3: pak$pkg_install(pkg = packages, lib = lib, upgrade = TRUE)
2: remote(function(...) get("pkg_install_make_plan", asNamespace("pak"))(...),
list(pkg = pkg, lib = lib, upgrade = upgrade, ask = ask,
start = start, dependencies = dependencies, loaded = loaded_packages(lib)))
1: stop("Subprocess is busy or cannot start")
R version 4.4.0 (2024-04-24) -- "Puppy Cup"
Platform: x86_64-pc-linux-gnu (64-bit)
Looking at the renv
source code, in the bioconductor.R
file, we have:
renv_bioconductor_init_biocmanager <- function(library = NULL) {
library <- library %||% renv_libpaths_active()
if (renv_package_installed("BiocManager", lib.loc = library))
return(TRUE)
ensure_directory(library)
install("BiocManager", library = library, prompt = FALSE)
TRUE
Within the install
function, we the have
# if users have requested the use of pak, delegate there
if (config$pak.enabled() && !recursing()) {
renv_pak_init()
return(renv_pak_install(packages, libpaths, project))
}
So, even though pak
installs fine (renv_pak_init
), once we've got it, it bugs out first time it needs to install something.
I don't understand why we don't get this error after installing BiocManager, though, because it happens repeatedly here (I think)
Can't we just direct them to wherever r-rig
installs these packages to?
So, after creating the codespace, it seems that config-r does not update the remote settings josn, but does so correctly when you run it manually.
Here's the output during codespace creation: