Migrate Installed R Packages Between R Versions
Overview
Detects all R installations on the current machine and migrates installed R packages between them. Provides find_routes() to discover R versions, manifest() to scan package libraries in a child R process, inventory() to compare two libraries, and ship() to install packages into a target R version using 'pak'. Includes a Shiny dashboard (open_hub()) for interactive source-to-target migration.
Bug fixes
- Fixed a second cause of shipped packages never showing up as installed, on the *copy* path (offline/preserve modes and online mode's local/private packages). A manifest's
libpathis the library directory shared by every package, but.copy_plan()passed it through as if it were the per-package source, so each "copy" recursively cloned the entire source library intotarget/<pkg>/— leaving no valid package where R looks and reporting a silent success. The package name is now joined onto the library path, which also restores the cross-major compiled-package warning (itslibs/check was always false before). Covered by a.copy_plan+copy_packagesregression test and an opt-in browser end-to-end test (COURIER_E2E=true). - R installation detection no longer drops installs intermittently on slow machines.
find_routes()probed each candidate with a hard 3 s timeout and silently discarded any that exceeded it, so a cold R start (antivirus, OneDrive-synced installs) made versions flicker in and out between runs. The default probe timeout is now 30 s, configurable viaoptions(courier.probe_timeout = ), and a probe that does time out is reported with a warning instead of vanishing; therig listtimeout was also raised from 5 s to 15 s.
Show all changes in 0.3.1Hide the rest of the changes in 0.3.1
- Fixed shipped packages never showing up as installed:
find_target_lib()and the pak install subprocess inherited the parent R session'sR_LIBS_USER, soship()installed into the *parent's* library while Compare scanned the real target. All subprocesses that launch another R now share one environment-stripping helper (child_r_env()), and the install destination is guaranteed to be a library thatmanifest()scans. - Library scans that time out are no longer cached as "empty library" for the rest of the session; timeouts are reported loudly in the log and the scan timeout was raised from 30 s to 5 min for slow machines.
- The "both installations share one library" warning no longer fires vacuously when both scans returned no packages.
Routing
- Online mode now means online: every package resolvable from CRAN / Bioconductor / GitHub is reinstalled via pak (binaries preferred). Only local/private packages with no online source are copied from the source library. (Previously pure-R CRAN packages were file-copied even in online mode, which is much slower than pak on synced/network libraries.)
Performance
- One manifest scan per library per session, shared across all tabs: a ship right after Compare reuses the Compare scans and spawns no scan subprocesses; the post-ship refresh rescans only the shipped-into library.
Dashboard UX
- **Bulk Dispatch** now shows a live hero panel during shipping (matching Custom Dispatch): packages delivered so far, the current package being installed, elapsed time, and the estimated total. The detailed log in the R console is also mirrored in the dashboard log pane.
- Both **Bulk Dispatch** and **Custom Dispatch** tables now default to showing only packages missing from the target after Compare, instead of all diff statuses. The filter chip bar lets you toggle other statuses.
- **Custom Dispatch** filter chips are now colour-coded — orange for source-side differences (newer in source, not in target), teal for target-side differences — matching Bulk Dispatch.
- **Custom Dispatch** comparison table gains a **Repo** column showing where the package comes from (CRAN, Bioconductor, GitHub, etc.). Packages with an unknown source are shown in red in both tables.
report_issue()— new exported function. Call it from the console after any error to open a pre-filled GitHub issue form in your browser with your R version, platform, courieR version, and the error message already populated. The dashboard's error modal gains a **Send Report** button that does the same in one click.- Custom Dispatch shows a live green hero panel while shipping: packages delivered so far, the package currently being copied/installed, elapsed time, and the estimated total.
- Time estimates (plan summary, ship confirmation, preview invoice) now come from per-machine calibrated rates persisted across sessions — every completed ship updates them — instead of fixed constants that were off by 100x on synced/network drives.
- Custom Dispatch source/target header now shows the R version, install location, and library path of both installations (was the bare executable path).
- After a Custom Dispatch shipment the comparison tables refresh automatically and the depot log says so; the refresh is logged when it completes.
library(courieR)startup message now includes a link to the user guide vignette (vignette("get-started", package = "courieR")).
From NEWS.md in the release
Install
Health
- OK13 OK2026-08-05
- NOTE12 OK, 1 NOTE2026-08-01
- OK5 OK2026-05-31
Documentation
- Help pages
- 21 (3 internal)includes a package overview page
- Examples that run
- 50%9 run in a plain check (3 of them under a condition) · 8 only when donttest examples are enabled (R CMD check --as-cran) · 1 never run
- Exported functions with examples
- 100%
- Documented parameters
- 99%
- Return-value docs
- 100%
- Help pages citing references
- 0%
Downloads
Repository
- PRs merged (all time)
- 100%
- Median days to close, 50 most recently updated closed issues
- not measured
- Median days to close, 50 most recently updated closed PRs
- 0
Stars over time
Commits over time
Commit identities over time
6 development-tooling and community-health practices detected across 3 families in the upstream repository
Checks run against github.com/lennon-li/courier on 2026-10-21.
The R CMD check workflow runs on Linux, macOS and Windows, and on R-devel
GitHub Pages site last deployed 2026-06-14 · The repository has a site deploy workflow
pkgdown site last built 2026-10-06
This repository shows signs of AI coding tools.
- Claude Codefirst seen 2026-05-05Seen in the repository: .claudeNamed in .Rbuildignore: .claudePull request it wrote: opened by a project memberCommits: at least 50 crediting it in the message
- Claude Sonnet 4.634 commits · May to Jun 2026
- Claude Opus 4.813 commits · Jun 2026
- Claude Fable 52 commits · Jun 2026
- Claude Sonnet 51 commit · Jul 2026
Dependencies
Installing courieR adds 49 packages (26 with compiled code, 42 MB of source tarballs). Heaviest: data.table 5.7 MB, bslib 5.6 MB, pak 3.8 MB.
Code & Tests
People & History
Package metadata
- First published
- 2026-05-30
- Total releases
- 3 / 1 yrs
- License
- MIT + file LICENSE OSI
- Download size
- 3.0 MB
Cite
Cite this package
Run in R for the authors' preferred citation:
citation("courieR")This package has no citation file, so citation() returns this entry built from DESCRIPTION.
Cite the R Observatory
For a number measured here: a download total, a coverage figure, an archival date.
From data release v2026-10-24, which the citation names so these numbers can be found later. More on citing and the projects behind them.