Live data from Hacker News

Show HN: Rv, a Package Manager for R

github.com

11–20 of 32 posts

Re: Show HN: Rv, a Package Manager for R

#11
post #2

Can this be used to effectively create R environments? I’m desperate for such a solution.

Doesn’t renv do that? What need does renv not meet for you?

Ultimately, you're right that `rv` and `renv` get you to the same spot, both create reproducible, isolated projects. `renv` has a few issues that we often hit that lead to `rv`.

`renv` is an iterative process of installing some packages, then snapshotting your project state, and then trying to reproduce. The time between the installation and snapshot can often lose information (think `install.packages("my_pkg", repos = "https://my-repo.com")`, your repo source is lost by time the snapshot occurs). You can also install incompatible versions over-time.

rv solves both of these problems because it will lock the source at the time of installation. Additionally, because it is declarative, we are able to resolve the full dependency tree before installing packages to ensure everything will be compatible.

While I am a big proponent of using rv, if renv fits your needs, then switching to rv may not be worth it. For our organization, we did have multiple issues with renv, so created a replacement for it that we hope others in the community will find useful to address their needs.

Re: Show HN: Rv, a Package Manager for R

#12

My biggest issue with R package management is version pinning. If I specify an older version of a package, R will fetch the latest versions of all its dependencies, regardless if they're compatible or not, which leads to manually chasing down and re-installing specific versions of dependencies and sub-dependencies one-by-one. Microsoft's CRAN time machine helped solved this, but I think they've recently shut it down…

Posit offers something similar to Microsoft’s CRAN Time Machine, but it works not only for CRAN, but also for Bioconductor and PyPI. You can add a date to the Public Posit Package Manager URL to access a snapshot of all packages from that day.

For example: https://packagemanager.posit.co/cran/2025-03-02

You can browse available snapshot dates here: https://packagemanager.posit.co/client/#/repos/cran/setup?sn...

This also works for PyPI and Python packages: https://packagemanager.posit.co/pypi/2025-03-04/simple

Re: Show HN: Rv, a Package Manager for R

#13

My biggest issue with R package management is version pinning. If I specify an older version of a package, R will fetch the latest versions of all its dependencies, regardless if they're compatible or not, which leads to manually chasing down and re-installing specific versions of dependencies and sub-dependencies one-by-one. Microsoft's CRAN time machine helped solved this, but I think they've recently shut it down…

Might be worth looking at groundhog, if you want a 'time machine' less likely to have a commercial motive

Re: Show HN: Rv, a Package Manager for R

#14

You might want to consider writing a plugin for R with Mise en Place https://mise.jdx.dev/core-tools.html This would extend your reach and might take some of the heavy lifting out of the project. (At least for the runtime portion. I don't think it will help with package management.)

I could be wrong but I feel like the overlap between mise and R users is likely very tiny

Re: Show HN: Rv, a Package Manager for R

#15
post #8

Maybe some code could be shared with the `uv`[1] to avoid re-implementing same things. [1] https://github.com/astral-sh/uv

We actually do use a bit of their code for the linking phase, which they seem to have taken from Cargo. For the rest, Python and R are way too different in how they handle packages to allow sharing code.

Re: Show HN: Rv, a Package Manager for R

#18
post #14

You might want to consider writing a plugin for R with Mise en Place https://mise.jdx.dev/core-tools.html This would extend your reach and might take some of the heavy lifting out of the project. (At least for the runtime portion. I don't think it will help with package management.)

I could be wrong but I feel like the overlap between mise and R users is likely very tiny

Tend to agree. Majority of users are leaving that icky computer stuff to RStudio and have no idea what happens behind the scenes.

Re: Show HN: Rv, a Package Manager for R

#20

Earlier quoted context omitted.

Doesn’t renv do that? What need does renv not meet for you?

Ultimately, you're right that `rv` and `renv` get you to the same spot, both create reproducible, isolated projects. `renv` has a few issues that we often hit that lead to `rv`. `renv` is an iterative process of installing some packages, then snapshotting your project state, and then trying to reproduce. The time between the installation and snapshot can often lose information (think `install.packages("my_pkg", repos…

I had similar issues in the past. Setting up renv, everything seems good, but after working in a project for a few weeks and installing packages, renv constantly complains about the library being out-of-sync and resolving these complaints took way longer than new ones came around. I think renv has good intentions, but there are just too many edge cases (Bioconductor, installing an experimental package from Github, weird package dependencies etc.), that it always failed me in a real-world scenario.
Post reply on HN