r-lib / pak

A fresh approach to package installation
https://pak.r-lib.org
639 stars 56 forks source link

Resolver hangs with too many repos #628

Open jeroen opened 1 month ago

jeroen commented 1 month ago

As discussed earlier, I run into a problem where the resolver hangs if there are too many repos.

> pak::pkg_install('ATACseqQC', dependencies=TRUE)
✔ Updated metadata database: 5.50 MB in 13 files.
✔ Updating metadata database ... done
.................... 

Would there be a way to give some hint to pak to prevent the combinatorial explosion in the solver?

One way to reproduce is this container:

docker run --rm -it --env MY_UNIVERSE=https://bioc.r-universe.dev/ --entrypoint=R ghcr.io/r-universe-org/build-wasm:latest

You can also reproduce it with another container running ubuntu:24.04 and setting:

options(repos = c(
    binaries = "https://bioc.r-universe.dev/bin/linux/noble/4.4",
    universe = "https://bioc.r-universe.dev", 
    CRAN = "https://p3m.dev/cran/__linux__/noble/latest",
    BioCsoft = "https://bioconductor.org/packages/3.20/bioc", 
    BioCann = "https://bioconductor.org/packages/3.20/data/annotation",
    BioCexp = "https://bioconductor.org/packages/3.20/data/experiment",
    fallback = "https://cloud.r-project.org", 
    archive = "https://cranhaven.r-universe.dev"
))