← Back to all sparks
P

pkgcache

INFRA · APIS
Velocity0.0

Cache CRAN-like metadata and package files. Contribute to r-lib/pkgcache development by creating an account on GitHub.

The metadata cache under pak now speaks to authenticated and corporate repositories.

package-managementr-librepositoriesauthenticationmetadata-cache
Current state
pkgcache maintains the package metadata cache that pak and pkgdepends build on, so its releases are about knowing where packages live and what platform they were built for. Version 2.2.4 added support for authenticated repositories through repo_auth(), the first time the cache could reach private registries directly. The releases around it track a moving target: Posit Package Manager behaviour, R Universe binaries, macOS binary availability per R version, Bioconductor version mapping, and most recently comments in DESCRIPTION and PACKAGES files following a change in R-devel.
Where it's heading
The work has shifted from CRAN-shaped assumptions toward the mixed reality of how R packages are actually distributed now — PPM snapshots, R Universe, private and authenticated registries, Bioconductor, and per-platform binaries across several R versions. Resilience is a recurring theme too: 2.2.5 makes an unreachable Bioconductor a non-fatal condition rather than a failure. MRAN's retirement, handled in 2.2.0 by resolving its prefix to PPM, is a reminder of how much of this package's job is absorbing other people's infrastructure changes.
Prediction
Expect continued tracking of R-devel metadata format changes and new binary platforms as R 4.6 lands, since both already appear in 2.2.5. Further work on authenticated repository handling is the plausible follow-on, given how recently that capability arrived.

Recent moves

  1. 4mo ago

    Parses comments in DESCRIPTION and PACKAGES files

    Tracks an R-devel change permitting comments in metadata files, including comments inside values, which the cache must handle before those files start appearing in the wild. It also stops treating an unreachable Bioconductor as fatal and adds macOS binaries for R 4.6 and later.

    View source ↗
  2. 1y ago

    repo_auth() brings authenticated repositories to the cache

    ⚡ SPARK

    The first release to let the metadata cache reach repositories that require credentials, which extends everything built on it — pak included — into private registry territory. The surrounding platform detection work for R Universe binaries serves the same widening of where packages are allowed to come from.

    View source ↗
  3. 1y ago

    Stops using source URLs for archived PPM packages

    Drops alternative source URLs for archived packages on Posit Package Manager, where they could resolve to a different package than the metadata described. Unnecessary there because PPM keeps metadata and files consistent.

    View source ↗
  4. 2y ago

    Handles macOS binaries for R 4.5 development builds

    Corrects macOS binary handling for the then-current R-devel and makes the platform detection more tolerant of macOS changes generally. One of several releases spent chasing binary availability per R version.

    View source ↗
  5. 2y ago

    Improves R to Bioconductor version matching

    A refinement of the mapping between R versions and Bioconductor releases. This mapping needs updating on every Bioconductor cycle, which is why it recurs through the package's history.

    View source ↗
  6. 3y ago

    MRAN prefix deprecated in favour of PPM; platform override added

    Redirects the MRAN prefix to Posit Package Manager ahead of MRAN's retirement, so snapshot-based reproducibility setups keep resolving. A new option and environment variable also allow overriding detected platform, useful for cross-platform resolution, and Bioconductor packages gain SystemRequirements metadata.

    View source ↗