Fixed an issue whererenv::dependencies() could failfor chunks which had alabel which was not a length-onecharacter vector. (#2144)
Fixed an issue wherefile.rename() could fail whenunpacking a package during installation in certain Windows environments.(#2156)
renv’s dependency discovery now supports usages ofbase::use(). (#2130)
Fixed an issue whererenv could fail to parse remotereferences containing an@ character. (#2135)
Fixed an issue whererenv::sysreqs(distro = <...>) could fail when passedan alternate distribution without a version specifier. (#2105)
Fixed an issue where multimode R documents containing chunkheaders which did not parse to an R list could cause dependencyinference to fail. (#2110)
Fixed an issue whererenv could erroneously recordpackages installed from Posit Package Manager snapshots as beinginstalled from CRAN. (#2104)
renv now only checks for archived packages duringinstallation whenoptions(renv.install.allowArchivedPackages = TRUE) is set.This fixes an issue whererenv could erroneously discoverthat Rcpp 1.3 was available when using the Posit Package Managerrepository.
Fixed an issue whererenv::dependencies() could failwith an unhelpful error message if the scanned document contained a YAMLheader whose contents was not a map. (#2117)
Fixed an issue whererenv::hydrate() could fail toinstall packages discovered in the user library duringrenv::init(). (#2109)
renv::update() now only updates the packagesinstalled in the project library by default.renv::update(all = TRUE) can be used to also check ifpackages installed in the default library are out-of-date, and installupdated copies into the project library. (#2108)
Fixed an issue where package installation could fail on ArchLinux with the error message “don’t know how to check sysreqs on thissystem”. (#2107)
renv now supports profile-specific comments within.gitignore and.renvignore files. These arecomments of the form#| <code>, where<code> is R code which should indicate if the.renvignore rules should apply. Typically, this should beof the form#| profile == "extra", or#| profile %in% c("extra", "other"). Note that only a smallsubset of base R functions are available for evaluation in this context.Note that the first section in a.renvignore implicitlyapplies to all profiles – if you want to limit it to just the defaultprofile, you can use#| profile == "default" for the firstline. (#1662)
The environment variableRENV_PATHS_VERSION can nowbe used to substitute the R version component normally used in library /cache paths. The provided path can include placeholders like%V for the full R version including the patch level, and%v for the R version without the patch level. Defaults toR-%v when unset. (#1687)
renv::install() gains thetransactionalargument, for parity withrenv::restore(). (#1109)
renv gains thesysreqs() function,which can be used to query the system packages required by a set of Rpackages. Functionality is currently available for Debian-baseddistributions, as well as Red Hat distributions.
On Linux,renv now uses the database fromhttps://github.com/rstudio/r-system-requirements whendetermining if an R package’s required system libraries are installed,and notifies the user which packages (if any) are missing during install/ restore.
Fixed an issue whererenv could fail to retrievecredentials registered for ‘github.com’ when querying URLs at‘api.github.com’.
Fixed an issue whererenv could stall when loading aproject and validating that the configured version of Bioconductor iscompatible with the version of R currently in use.
renv::snapshot() no longer fails to generate a newlockfile if the project contains a lockfile which could not be read orparsed.
Fixed an issue where lockfiles containing unicode characters werenot correctly written or read with versions of R (< 4.2.0) onWindows. (#2091)
Fixed an issue where very long lockfiles could be truncated onwrite. (#2089)
Fixed an issue whererenv inadvertently made webrequests in tests duringR CMD check.
renv now includes additional package DESCRIPTIONfields in the lockfile. This can be useful for validating the provenanceof packages recorded in the lockfile, and also for applications usingrenv which would like to recompute the hash used forpackage caching from the lockfile itself.
If needed, old-style lockfiles can be generated by setting the optionoptions(renv.lockfile.version = 1). Note that this versionofrenv remains compatible both with the older (minimal)lockfiles, as well as with the newer lockfiles in this release.(#2057)
Therenv sandbox is now unlocked on exit after acall torenv::use(). This should alleviate issues seenwhere R’s attempts to clean up the temporary directory could fail due toinadequate permissions on the sandbox directory. (#2076)
Fixed an issue whererenv::restore() did not respectthe named repository within the lockfile when installing packages fromthe archives of the configured package repositories. (#2081)
Fixed an issue whererenv::snapshot() could fail ifinvoked within a project containing empty or invalid.ipynbfiles. (#2073)
Fixed an issue where R package installation could fail if theproject depended on a package whose current version available from theconfigured package repositories required on a newer version of R thanwhat was currently installed, even if that package need not be updated.(#2071)
Fixed an issue whereRENV_CONFIG_EXTERNAL_LIBRARIESwas incorrectly split when using Windows paths. (#2069)
Fixed an issue whererenv failed to restore packagesinstalled from r-universe when the associated lockfile record had noRemoteRef field. (#2068)
renv now detects dependencies from usages ofutils::citation(). (#2047)
Fixed an issue where packages installed from r-universe via anexplicit URL remote could not be restored. (#2060)
Fixed an issue where the repositories provided torenv::init() were ignored when also initializingrenv with a specific version of Bioconductor.
renv::install() gains theincludeparameter, which can be useful when you’d like to install a subset ofdependencies within a project while also respecting any declared remotesin that project’sDESCRIPTION file. (#2055)
Fixed an issue whererenv could fail to check forupdates for packages installed usingpak without anexplicit branch specified. (#2040)
renv::use() no longer re-installs packages which arealready installed and compatible with the requested packages.(#2044)
Fixed an issue whererenv::init() could fail whenusing named remotes in a DESCRIPTION file’sRemotes: field.(#2055)
Fixed an issue where ignore rules of the form!*.*were not parsed and handled correctly during dependency discovery.(#2052)
Fixed an issue whererenv erroneously reported thatinstalled packages were cached when the cache was not writable.(#2041).
renv now supports updating of currently-installedpackages viarenv::install() when configured to usepak. (#2037)
Fixed an issue whererenv library paths were notproperly reset following a suspend / resume in RStudio Server.(#2036)
renv::run() gains theargs parameter,which can be used to pass command-line arguments to a script.(#2015)
renv now infers a dependency onrmarkdown andknitr for R scripts whichinclude YAML front-matter. (#2023)
The performance ofrenv’s built-in JSON reader hasbeen improved. (#2021)
Fixed an issue whererenv could erroneously create abinding called ‘object’ in the global environment on startup.(#2017)
Fixed an issue where headers were not properly passed toavailable.packages() duringrenv bootstrap.(#1942)
renv now assumes that Artifactory packagerepositories will use a CRAN-like layout of packages for packages in thearchive. (#1996)
renv now includes compiled extensions on Linux +macOS. These extensions are primarily used to improve the performance ofrenv::dependencies() and other static analysis code.Support for Windows may come in a future release.
Fixed an issue whererenv::snapshot() could fail ifthe project contained a call tomodule() with no arguments.(#2007)
On Linux,renv now emits a message on load if the Rtemporary directory is within a folder that has been mounted as‘noexec’. This message can be suppressed by setting theRENV_TEMPDIR_NOEXEC_CHECK=FALSE environmentvariable.
Fixed a performance regression inrenv::dependencies(). (#1999)
Fixed an issue whererenv tests could fail if theparallel package was loaded during test execution.
renv now determines a package repository’s typethrough the HTTP headers provided when accessingsrc/contrib/PACKAGES. This is mainly relevant whendetecting Nexus and Artifactory repositories.
Fixed an issue where repository URLs were inappropriatelytransformed into binary repository URLs on Linux. (#1991)
Fixed an issue where code followingsource("renv/activate.R") in the project.Rprofile was not invoked for projects using RStudio.(#1990)
renv now infers a dependency on theragg package when theragg_png device is usedin R Markdown / Quarto documents, for documents using the codeknitr::opts_chunk$set(dev = "ragg_png"). (#1985)
renv now automatically generates a lockfile whenloading a project containing amanifest.json file (typicalfor application bundles published to Posit Connect). (#1980,
renv::install() now errs if an incompatibletype argument is provided.
renv::checkout() now also checks out the version ofrenv available and associated with the requested snapshotdate. (#1966)
Fixed an issue whererenv::hydrate() did not hydratepackages which were also listed as dependencies within a project’sDESCRIPTION file. (#1970)
Fixed an issue whererenv::checkout() omitted somefields from lockfile records when usingactions = c("snapshot", "restore"). (#1969)
renv gains the functionrenv::retrieve(), which can be used to download packageswithout installing them. This is primarily useful in CI / CD scenarios,where you might want to download packages in a single stage beforeattempting to install / restore them. (#1965)
renv now preservesRemote fieldspresent on packages installed from public package repositories (e.g. https://r-universe.dev/).(#1961)
Fixed an issue whererenv::load() could fail to loadan alternate project whenoptions(renv.config.autoloader.enabled = FALSE) was set.(#1959)
renv now emits clickable hyperlinks for runnablecode snippets and help, for front-ends which support theide:run andide:help ANSI escapes.
renv::init(bioc = "<version>") now prompts theuser in interactive sessions when requesting a version of Bioconductorwhich is not compatible with the current version of R. (#1943)
renv::restore() gains thetransactionalargument, which can be used to control whetherrenv willallow successfully-installed packages remain in the project library evenif a package fails to install during a later step. (#1109)
renv now infers a dependency on thexml2 package for projects using thetestthat::JunitReporter for tests. (#1936)
Fixed an issue whererenv::dependencies() could emita warning when attempting to parse chunks using chunk options like#| eval: c(1, 2). (#1906)
renv::install() now properly delegates thetype andrebuild arguments topakwhenoptions(renv.config.pak.enabled = TRUE) is set.(#1924)
renv now infers a dependency on thesvglite package if it detects calls of the formggsave(filename = "path.svg"). (#1930)
renv now supports setting of GitHub authenticationcredentials via any ofGITHUB_TOKEN,GITHUB_PAT, andGH_TOKEN. (#1937)
renv now also passes any custom headers available toutils::available.packages() during bootstrap.(#1942)
Fixed an issue whererenv could fail duringinstallation of packages stored within repository sub-directories, ifthat repository also contained a top-level DESCRIPTION file.(#1941)
renv now normalizes lockfile entries forBioconductor packages installed viapak::pkg_install(), tohelp prevent spurious diffs being produced viarenv::status(). (#1920)
renv::install() now respects thepromptparameter whenpak is enabled, as viaoptions(renv.config.pak.enabled = TRUE). (#1907)
Fixed an issue withrenv’spakintegration whererenv could install the wrong version of aGitHub package during restore ifoptions(renv.config.pak.enabled = TRUE) was set.(#1883)
renv no longer interacts with the user duringautoloading, which coincides with R startup. If the IDE offers a sessioninit hook (RStudio does), loading is deferred until startup is completeand interaction is possible. Otherwise, any suggested renv actions, suchasrenv::restore(), are emitted as a message for the userto act on. (#1879, #1915).
Fixed an issue where installation of packages from local sources,as viainstall("<package>", repos = NULL, type = "source"),could fail. (#1880)
A new function,renv::lockfile_validate(), can beused to validate yourrenv.lock against a default or customschema. (#1889)
renv’s activate script failed toreport version conflict errors when starting up. (#1874)Fixed an issue where downloads could fail with curl >= 8.7.1.(#1869)
Fixed an issue whererenv::snapshot() did notproperly normalize package records generated from packages installedusing thepak package, e.g. viapak::pkg_install("cran::<package>").
Fixed an issue whererenv could incorrectly promptthe user to record a version ofrenv installed from GitHubin some cases. (#1857)
renv::load() now delegates tobase::load() when it detects that the call was likelyintended forbase::load(), butrenv::load()was used instead (e.g. becausebase::load() was masked byrenv::load()).
renv::update() gains thelock argument,which can be used to instructrenv to automatically updatethe lockfile after the requested packages have been updated.(#1849)
Fixed an issue whererenv could fail to update theproject autoloader after callingrenv::upgrade().(#1837)
Fixed an issue where attempts to install binary packages fromolder PPM snapshots could fail. (#1839)
renv now uses a platform-specific prefix on Linuxfor library and cache paths by default with R (>= 4.4.0). This isequivalent to settingRENV_PATHS_PREFIX_AUTO = TRUE. Ifnecessary, this behavior can be disabled by settingRENV_PATHS_PREFIX_AUTO = FALSE in an appropriate R startupfile. (#1211)
renv now only writes a.renvignore fileinto the cache directory if the cache appears to be part of the currentproject.
renv now reports missing system libraries as part ofits ABI checks inrenv::diagnostics().
Fixed an issue whererenv::install(lock = TRUE)produced lockfiles containing records with extraneous data.(#1828)
renv::install() gains thelockargument. WhenTRUE, the project lockfile will be updatedafter the requested packages have been successfully installed.(#1811)
renv now supports the use of GitHub Enterpriseservers with thegitcreds package for authenticationcredentials. (#1814)
renv::dependencies() now treats#| eval: !expr <...> chunk options as truthy bydefault, implying that such chunks are scanned for their R packagedependencies. (#1816)
renv::dependencies() now requires usages of theimport package tobe namespace-qualified in order to be handled via static analysis; thatis,import::from(<pkg>) is parsed for dependencies,butfrom(pkg) is not. (#1815)
renv::load() gains theprofileargument, allowing one to explicitly load a specific profile associatedwith anrenv project. Seevignette("profiles", package = "renv") orhttps://rstudio.github.io/renv/articles/profiles.html for moredetails.
renv::dependencies() no longer includesR dependency versions declared from aDESCRIPTION file in its output. (#1806)
Fixed an issue whererenv could fail to inferdependencies from R Markdown code chunks using engine ‘R’ (upper-case)rather than ‘r’ (lower-case). (#1803)
Fixed an issue whererenv did not report out-of-syncpackages when one or more packages used in the project were notinstalled. (#1788)
Fixed an issue whererenv could over-aggressivelyactivate P3M repositories when initializing a project. (#1782)
renv::status() now notifies the user if the versionof R recorded in the lockfile does not match the version of R currentlyin use. (#1779)
Fixed an issue where packages could appear multiple times in thelockfile, if that package was installed into multiple library paths.(#1781)
Installation of historical binaries of packages is once againenabled, now using thePositPublic Package Manager (P3M) service instead of Microsoft’s (nowdefunct) MRAN service.
renv::init() now respects theRemotes:field declared in a project’sDESCRIPTION file, if any.(#1522)
renv::embed() now supports Quarto Markdown(.qmd) files. (#1700)
renv now sets theR_INSTALL_TAR environment variableto match the defaulttar executable (if any) wheninstalling packages. (#1724)
renv now uses--ssl-revoke-best-effort by defaultwhen downloading files usingcurl on Windows.(#1739)
Fixed an issue whererenv::install() could fail todetect incompatible recursive package dependencies. (#1671)
renv::install() now records remote information forpackages installed from CRAN-like repositories, and uses thatinformation when generating a lockfile and restoring those packages.This helps ensure that packages installed within an renv project viacalls likerenv::install("<pkg>", repos = "<repos>") canstill be successfully restored in future sessions. (#1765)
renv::install() now lazily resolves project remotes.(#1755)
renv::init() now respects Remotes declared within aproject’sDESCRIPTION file, if any.
Callingrenv::activate() without explicitlyproviding theprofile argument now preserves the currentprofile, if any. Userenv::activate(profile = "default") ifyou’d like to re-activate a project using the default profile.(#1217)
Fixed an issue whererenv would try to prompt forthe installation ofBiocManager when activating a projectusing Bioconductor. (#1754)
Fixed an issue where directories containing a large number offiles could causerenv to fail to activate a project.(#1733)
Expanded the set of Linux distributions detected for automatictransformation of Posit Package Manager URLs to install binary packages.renv now correctly detects Red Hat Enterprise Linux 9,Rocky Linux 8 and 9, SLES 15 SP4 and SP5, Debian 11 and 12, AlmaLinux 8and 9, and Amazon Linux 2. (#1720, #1721)
Fixed an issue whererenv could warn the projectappeared to be out-of-sync when using packages installed without anexplicit source recorded. (#1683)
renv::install() gains theexcludeargument, which can be useful when installing a subset of projectdependencies.
Fixed an issue where PPM repositories were not appropriatelytransformed into the correct binary repository inrenv::restore() when using pak.
renv::init() no longer prompts the user for theintended action for projects containing a library with only renvinstalled. (#1668)
Fixed an issue where non-interactive usages ofrenv::init() could fail with projects containing aDESCRIPTION file. (#1663)
Fixed an issue that could cause code within a project.Rprofile to execute before the project had been loaded inRStudio. (#1650)
renv::snapshot() andrenv::status()gain thedev argument. This can be used when you’d like tocapture package dependencies from theSuggests field of yourpackage’s DESCRIPTION file. (#1019)
renv now parses packageNAMESPACE files for importeddependencies. (#1637)
renv no longer locks the sandbox by default.
Fixed an issue where renv used the wrong library paths whenattempting to activate the watchdog. This could cause a 10 second delaywhen activating the sandbox.
Fixed an issue where authentication headers could be duplicatedwhen using thelibcurl download method. (#1605)
renv::use() now defaults to settingisolate = TRUE whensandbox = TRUE.
Fixed an issue where the renv watchdog could fail to load,leading to slowness in activating the sandbox on startup.(#1617)
Fixed an issue where renv did not display warnings / errors fromrenv::snapshot() whenoptions(renv.verbose = FALSE) was set. The display of thesemessages is now controlled via therenv.caution.verbose Roption. (#1607, #1608)
renv::load() now notifies the user if thesynchronization check took an excessive amount of time due to the numberof files being scanned in the project. (#1573)
renv::init() gains theload argument,making it possible to initialize a project without explicitly loadingit. (#1583)
renv now uses a lock when synchronizing installed packages withthe cache. This should help alleviate issues that can arise whenmultiple R processes are installing and caching packages concurrently.(#1571)
Fixed a regression in parsing expressions within R Markdown chunkoptions. (#1558)
Fixed an issue that preventedrenv::install() fromfunctioning when source-only repositories were included.(#1578)
Fixed a logic error in readingRENV_AUTOLOAD_ENABLED. (#1580)
renv::restore() no longer runs without prompting onload if the library is empty. (#1543)
renv::repair() now checks for installed packageswhich lack a known remote source, and updates theirDESCRIPTION files if it can infer an appropriate remotesource. This typically occurs when a package is installed from localsources, but appears to be maintained or published on a remoterepository (e.g. GitHub). This was previously done inrenv::snapshot(), but we’ve rolled back that change as theprompting was over-aggressive. (#1574)
renv::status() now first reports on uninstalledpackages, before reporting on used <-> installed mismatches.(#1538)
When theRENV_STARTUP_DIAGNOSTICS environmentvariable is set toTRUE, renv now displays a shortdiagnostics report after a project’s autoloader has been run. This canbe useful when diagnosing why renv is slow to load in certain projects.(#1557)
renv now ensures the sandbox is activated on load, for Rprocesses which are launched with the renv sandbox on the library paths.(#1565)
renv::restore() no longer erroneously prompts whendetermining the packages which need to be installed. (#1544)
renv::update() now ensures thepromptparameter is properly respected during package installation.(#1540)
renv::activate() no longer erroneously preserves theprevious library paths after restarting the session within RStudio.(#1530)
Use correct spelling of IRkernel package (#1528).
HonorR_LIBCURL_SSL_REVOKE_BEST_EFFORT when using anexternalcurl.exe binary to download files.(#1624)
Newrenv::checkout() installings thelatest-available packages from a repository. For example,renv::checkout(date = "2023-02-08") will install thepackages available on 2023-02-08 from the PositPackage Managerrepository. Theactions argument allows you choose whethera lockfile is generated from the provided repositories (“snapshot”), orwhether packages are installed from the provided repositories(“restore”).
renv::deactivate() gains acleanargument: whenTRUE it will delete all renvfiles/directories, leaving the project the way it was found.
renv::init() now usesPosit Public Package Managerby default, for new projects where the repositories have not alreadybeen configured externally. See the optionsrenv.config.ppm.enabled,renv.config.ppm.default, andrenv.config.ppm.url in?config for moredetails (#430).
renv::lockfile_create(),renv::lockfile_read(),renv::lockfile_write()andrenv::lockfile_modify() provide a small family offunctions for interacting with renv lockfiles programmatically(#1438).
Handling of development dependencies has been refined.renv::snapshot() andrenv::status() no longertrack development dependencies, whileinstall() continuesto install them (#1019).Suggested packages listed inDESCRIPTION files are declared as development dependenciesregardless of whether or not they’re a “package” project.
MRAN integration is now disabled by default, pending the upcomingshutdown of Microsoft’s MRAN service. Users who require binaries ofolder R packages on Windows + macOS can consider using the instance ofCRAN mirrored by thePositPublic Package Manager (#1343).
Development versions of renv are now tracked using the Git SHA ofthe current commit, rather than a version number that’s incremented onevery change (#1327). This shouldn’t have any user facing impact, butmakes renv maintenance a little easier.
Fixed an issue causing “restarting interrupted promiseevaluation” warnings to be displayed when querying available packagesfailed. (#1260)
renv::activate() uses a three option menu thathopefully make your choices more clear (#1372).
renv::dependencies() now discovers R packagedependencies inside Jupyter notebooks (#929).
renv::dependencies() includes packages used by userprofile (~/.Rprofile) ifrenv::config$user.profile() isTRUE. They areset as development dependencies, which means that they will be installedbyinstall() but not recorded in the snapshot.
renv::dependencies() only extracts dependencies fromtext in YAML headers that looks like valid R code (#1288).
renv::dependencies() no longer treatsbox::use(module/file) as using packagemodule(#1377).
renv::init() now prompts the user to select asnapshot type if the project contains a top-level DESCRIPTION file(#1485).
renv::install(type = "source") now ensures sourcerepositories are used in projects usingPPM. (#927)
renv::install() activates Bioconductor repositorieswhen installing a package from a remote (e.g. GitHub) which declares aBioconductor dependency (via a non-empty ‘biocViews’ field)(#934).
renv::install() respects the project snapshot type,if set.
renv::install() now keeps source when installingpackages from source (#522).
renv::install() now validates that binary packagescan be loaded after installation, in a manner similar to source packages(#1275).
renv::install() now supports Bioconductor remotes ofthe formbioc::<BiocVersion>/<Package>, forinstalling packages from a particular version of Bioconductor. Aliaseslike ‘release’ and ‘devel’ are also supported (#1195).
renv::install() now requires interactiveconfirmation that you want to install packages (#587).
renv::load() gives a more informative message if alockfile is present but no packages are installed (#353).
renv::load() no longer attempts to query packagerepositories when checking if a project is synchronized (#812).
renv::load() no longer duplicates entries on thePATH environment variable (#1095).
renv::restore() can now usepak::pkg_install() to install packages whenpak integration is enabled. SetRENV_CONFIG_PAK_ENABLED = TRUE in your project’s.Renviron if you’d like to opt-in to this behavior. Notethat this requires a nightly build ofpak (>=0.4.0-9000); see https://pak.r-lib.org/dev/reference/install.html formore details.
renv::restore() now emits an error if called withina project that does not contain a lockfile (#1474).
renv::restore() correctly restores packagesdownloaded and installed fromr-universe (#1359).
renv::snapshot() now standardises pak metadata soCRAN packages installed via pak look the same as CRAN packages installedwith renv orinstall.packages() (#1239).
Ifrenv::snapshot() finds missing packages, a newprompt allows you to install them before continuing (#1198).
renv::snapshot() no longer requires confirmationwhen writing the first snapshot, since that’s an action that can easilybe undone (by deletingrenv.lock) (#1281).
renv::snapshot() reports if the R version changes,even if no packages change (#962).
renv::snapshot(exclude = <...>) no longerwarns when attempting to exclude a package that is not installed(#1396).
renv::status() now uses a more compact display whenpackages have some inconsistent combination of being installed, used,and recorded.
renv::status() now works more likerenv::restore() when package versions are different(#675).
renv::update() can now update packages installedfrom GitLab (#136) and BitBucket (#1194).
renv::settings$package.dependency.fields() now onlyaffects packages installed directly by the user, not downstreamdependencies of those packages.
renv functions give a clearer error ifrenv.lock hassomehow become corrupted (#1027).
Fixed an issue whererenv::install("bioc::<package>") could fail ifBiocManager was not already installed. (#1184)
Fixed an issue where package names were not included in theoutput ofrenv::diagnostics(). (#1182)
The clarity of the message printed byrenv::status()has been improved; in particular, renv should better report therecommended actions when a package required by the project is notinstalled.
renv::snapshot() gains theexcludeargument, for explicitly excluding certain packages from the generatedlockfile.
Fixed an issue where renv was passing the wrong argument name toinstalled.packages(), causing usages of renv to fail with R(<= 3.4.0). (#1173)
renv now sets theSDKROOT environment variable onmacOS if it detects that R was built using an LLVM build ofclang on macOS.
renv::install() now parses the remotes includedwithin, for example, aDESCRIPTION file’sConfig/Needs/... field.
renv now checks that the index directory is writable beforeattempting to use it, e.g. for theR available packagesindex maintained by renv. (#1171)
renv now checks that the version ofcurl used fordownloads appears to be functional, and reports a warning if it does not(for example, because a requisite system library is missing). Theversion ofcurl used for downloads can also be configuredvia theRENV_CURL_EXECUTABLE environment variable.
renv gains the configuration optioninstall.remotes,which can be used to control whether renv attempts to read and use theRemotes: field included with installed packages. This canbe set toFALSE if you’d like to ignore this field;e.g. because you know they will not be accessible. (#1133)
General performance optimizations. In particular,renv::update(check = TRUE) should now execute muchfaster.
renv now stores project settings withinrenv/settings.json rather thanrenv/settings.dcf. Old settings will be automaticallymigrated.
The renv sandbox is now placed within the renv cache directory.(#1158)
Fixed an issue whererenv::status() coulderroneously report a project was out-of-sync when using explicitsnapshots. (#1159)
Fixed an issue whererenv::hydrate() would printspurious warnings. (#1160)
renv::status() now suggests runningrenv::restore() if there are no packages installed in theproject library. (#1060)
Fixed an issue where renv would fail to queryr-universe repositories.(#1156)
renv no longer tries to set theSDKROOT environmentvariable on macOS for R (>= 4.0.0).
Fixed an issue where installation of Bioconductor packages couldfail whenBiocManager was not installed. (#1156,#1155)
Fixed an issue where the amount of time elapsed reported byrenv::install() failed to include the time spent retrievingpackages.
The performance ofrenv::snapshot() hasimproved.
renv now maintains an index of available packages, as retrievedfrom the active package repositories, that is shared acrossR sessions. This should improve renv’s performance whenquerying for available packages across multiple differentRsessions.
renv::hydrate() gains thepromptparameter. WhenTRUE (the default), renv will prompt forconfirmation before attempting to hydrate the active library.
Improved handling of package installation via SSH URLs withgit. (#667)
Improved handling of R version validation when using projectswith Bioconductor. If you find renv is erroneously reporting that yourversion of R is incompatible with the version of Bioconductor you areusing, you can setoptions(renv.bioconductor.validate = FALSE) to disable thisvalidation behaviour. (#1148)
Package names can now be associated with remotes inrenv::install(); for example, you can userenv::install("igraph=igraph/rigraph") to install theigraph package. This is mainly important when using therenv.auth authentication tools, where the package name of aremote needs to be declared explicitly. (#667)
Fixed an issue that could preventrenv::restore()from functioning when attempting to install packages which had beenarchived on CRAN. (#1141)
renv::install() gains thedependenciesargument, which behaves similarly to the equivalent argument inremotes::install_*(). In particular, this can be set tofields likeConfig/Needs/dev to tell renv to use customDESCRIPTION fields for dependency resolution in installation.
Fixed an issue where the function variant of therenv.auth option was not resolved correctly.(#667)
renv::install() now supports remotes with a trailingslash – such slashes are now removed. (#1135)
Integration with the RStudio (Posit) Package Manager is nowdisabled by default on aarch64 Linux instances.
TheRENV_CACHE_MODE environment variable can nowalso be used to adjust the permissions set on downloaded packagetarballs / binaries. (#988)
Fixed an issue where fields of the formRemotes.1could enter lockfile records for older versions of R. (#736)
Fixed the performance ofrenv::update() in caseswhere integration with MRAN is enabled.
Fixed an issue where package installation usingpakcould fail in some cases.
renv_file_find() can now scan up to the rootdirectory in Docker containers. (#1115)
renv no longer uses the R temporary directory on Windows for thesandbox. The sandbox directory can be customized via theRENV_PATHS_SANDBOX environment variable if required.(#835)
renv now reports the elapsed time when installing packages.(#1104)
For projects using “explicit” snapshots, renv now reports if apackage is required by the project, but the package is not currentlyinstalled. (#949)
Fixed an issue whererenv::snapshot() could fail todetect when no changes had been made to the lockfile.
Fixed an issue where renv could emit JSON lockfiles which couldnot be parsed by external JSON readers. (#1102)
renv now marks the sandbox as non-writable, which shouldhopefully alleviate issues where attempts to update installed packageswould inadvertently install the updated package into the sandbox.(#1090)
renv::use() gains thesandbox argument,which allows one to control whether the system library is sandboxedafter a call torenv::use(). (#1083)
The path to the Condaenvironment.yml file createdby renv can now be customized via theRENV_PATHS_CONDA_EXPORT environment variable. We recommendsetting this within your project-local.Renviron file asappropriate. (#1089)
Fixed an issue where the renv sandbox location did not respectthe active renv profile. (#1088)
renv now supports installation of packages with remotes of theform<package>=<remote>. However, the providedpackage name is ignored and is instead parsed from the remote itself.(#1064)
renv now passes along the headers produced by therenv.download.headers option when bootstrapping itself inthe call toutils::download.file(). (#1084)
renv now reports ifrenv::snapshot() will change orupdate the version of R recorded in the lockfile. (#1069)
renv now supports theinstall.packages.check.sourceR option, which is used to allow R to query source repositories even ifthe optionoptions(pkgType = "binary") is set.(#1074)
renv better handles packages containing git submodules wheninstalled from GitHub remotes. (#1075)
renv now handles local sources within the current workingdirectory. (#1079)
The renv sandbox is once again enabled by default. On Unix, thesandbox is now created by default within the project’srenv/sandbox library. On Windows, the sandbox is createdwithin the R session’stempdir(). The path to the renvsandbox can be customized via theRENV_PATHS_SANDBOXenvironment variable if required.
Fixed an issue whererenv::status() could reportspurious changes when comparing packages installed usingpak in some cases. (#1070)
renv::restore() now also ensures the projectactivate script is updated after a successful restore. (#1066)
Fixed an issue where renv could attempt to install a package fromthe repository archives even whentype = "binary" was set.(#1046)
Fixed an issue where package installation could fail when the Rsession is configured to use multiple repositories, some of which do notprovide any information on available packages for certain binary arms ofthe repository. (#1045)
renv now usesjsonlite for reading lockfiles whenloaded. This should help ensure useful errors are provided formanually-edited lockfiles which contain a JSON parsing error. If thejsonlite package is not loaded, renv will fall back to itsown internal JSON parser. (#1027)
Fixed an issue that would cause renv to fail to source the user~/.Rprofile if it attempted to register global callinghandlers, e.g. asprompt::set_prompt() does.(#1036)
(Linux only) renv now resets ACLs on packages copied to thecache, to avoid persisting default ACLs that might have been inheritedon packages installed into a local project library. If desired, thisbehavior can be disabled by setting theRENV_CACHE_ACLSenvironment variable toFALSE. If you need finer controlover ACLs set on packages moved into the cache, consider defining acustom callback via therenv.cache.callback R option.(#1025)
Fixed an issue where.gitignore inclusion rules forsub-directories were not parsed correctly by renv for dependencydiscovery. (#403)
Fixed an issue where renv could report spurious diffs withinrenv::status() when comparing package records installedfrompak versus the default R package installer.(#998)
Fixed an issue whererenv::use_python() could causethe Requirements field for packages in the lockfile to beunintentionally dropped. (#974)
The R optionrenv.cache.callback can now be set, torun a user-defined callback after a package has been copied into thecache. This can be useful if you’d like to take some action on thecached package’s contents after the package has been moved into thecache.
(Unix only) TheRENV_CACHE_MODE environment variablecan now be used to change the access permissions of packages copied intothe cache. When set, after a package is copied into the cache, renv willusechmod -Rf to try and change the permissions of thecache entry to the requested permissions.
(Unix only) TheRENV_CACHE_USER environment variablecan now be used to change the ownership of folders copied into thecache. When set, after a package is copied into the cache, renv will usechown -Rf to try and change the ownership of that cacheentry to the requested user account.
Fixed an issue where repositories containing multiple packages insub-directories could fail to install. (#1016)
Fixed an issue where indexing of packages in the package cellarcould be slow. (#1014)
Fixed an issue where installation of packages from Bioconductor’sbinary Linux package repositories could fail. (#1013)
renv::restore() now supports restoration of packagesinstalled fromR-Forge.(#671)
Fixed an issue whererenv::init(bioconductor = TRUE)would not update the version of Bioconductor used if a project settinghad already been set.
It is now possible to “update” an existing lockfile by usingrenv::snapshot(update = TRUE). When set, any recordsexisting in the old lockfile, but not the new lockfile, will bepreserved. (#727)
Fixed an issue where renv could fail to parse Git remotes forusers whose username contains a number. (#1004)
renv no longer infers a dependency on the “quarto” R package inprojects containing a_quarto.yml file. (#995)
Fixed an issue where renv could fail to download a package fromMRAN if a compatible source package of the same version was availablefrom the active R repositories. (#990)
renv now reports permission errors during download more clearly.(#985)
Fixed an issue whereRENV_PATHS_LIBRARY_ROOT_ASISwas not interpreted correctly. (#976)
renv::modify() gains thechangesargument, which can be used to modify a project lockfilenon-interactively.
renv::clean() now returns the project directory, asdocumented. (#922)
Fixed an issue where renv could fail to parse embedded YAML chunkoptions in R Markdown documents. (#963)
renv now sets default placeholder names for therepos R option, for any repository URLs which happen to beunnamed. (#964)
Fixed an issue where renv didn’t respect thePATHordering when discovering Python installations viarenv_python_discover(). (#961)
Fixed an issue where renv could fail to install packagescontaining multibyte unicode characters in their DESCRIPTION file.(#956)
Fixed detection of Rtools 4.2 (#1002)
~/.local/share/renv. (#953)A variety of fixes for R CMD check.
renv gains an experimental function,renv::autoload(), to be used as a helper for automaticallyloading a project for R processes launched within a sub-directory ofthat project. See?renv::autoload for moredetails.
renv will now print a warning message when attempting to read alockfile containing merge conflict markers (as from e.g. a git merge).(#945)
Fixed an issue whererenv::install() could installinto the wrong library path on Windows, if the R installation had asite-wide profile that mutated the library paths. (#941)
Fixed an issue whererenv::install() would fail tofind a package within the cache when using an abbreviated commit hashfor installation. (#943)
Fixed an issue where renv’s automatic snapshot was not run aftercalls torenv::install() in some cases. (#939)
Fixed an issue where renv would incorrectly copy a package fromthe cache, if the cached version of the package and the requestedversion of the package had the same package version, even if they wereretrieved from different sources. (#938)
The path to an renv tarball can now be set via the environmentvariableRENV_BOOTSTRAP_TARBALL, to be used to help renvbootstrap from local sources. This can either be the path to a directorycontaining renv source tarballs, or the path to the tarballitself.
Fixed an issue where the R site library would not beappropriately masked for resumed RStudio sessions. (#936)
Fixed an issue where renv inadvertently inserted extra newlinesinto aDESCRIPTION file when addingRemotesfields after install. (#914)
Fixed an issue where packages installed from a remotesub-directory would fail to install when later re-installed from thecache. (#913)
renv now recognizes YAML chunk options of the form#| key: value when used in R Markdown documents.(#912)
Fixed an issue where the R site library was visible in renvprojects with the system library sandbox disabled.
Fixed an issue where renv could update the wrong.gitignore in R processes launched bycallr(e.g. indevtools::install). (#910)
Fixed an issue where renv could fail to read mis-encodedDESCRIPTION files. (#908)
Fixed an issue whereconfig$cache.symlinks() wouldreportNULL when unset. (#906)
The development branch for renv has moved from master tomain.
renv package records in the lockfile now include aRequirements entry, which gives a list of R packages thispackage depends on in some way. This is primarily for internal use bythepak package.
Fixed an issue where packages containing DESCRIPTION files usinga latin1 encoding would not be read correctly by renv.
Fixed an issue that could causerenv::dependencies()to fail when a malformedDESCRIPTION file was encountered.(#892)
The path to the project-local renv folder can now be configuredvia theRENV_PATHS_RENV environment variable. This can beuseful if you’d prefer to store your project’s renv resources within analternate location in the project. (#472)
renv now uses an external library by default for R packageprojects, with the library located withintools::R_user_dir("renv", "cache"). This directory can beconfigured via theRENV_PATHS_LIBRARY_ROOT environmentvariable if desired. Seevignette("packages", package = "renv") for more details.(#384)
renv now uses the repositories as defined within the projectlockfile (if any) when attempting to bootstrap itself in a project.(#820)
The renv sandbox is now disabled by default – see #614 for moredetails.
renv gains the functionrepair(), to be used toattempt to repair the project library when links into the global packagecache appear to be broken. (#378)
Fixed an issue where the staging library used during installcould fail to inherit the same directory permissions as the targetlibrary itself. (#331)
Fixed an regression which causedrenv::history() tofail. (#886)
renv gains experimental support for thepak package. SetRENV_CONFIG_PAK_ENABLED = TRUE in an appropriate.Renviron file to enablepak integration. Whenenabled, calls torenv::install() will usepakto download and install packages.
renv::init() gains thebioconductorargument, to be used to initialize a project with a particularBioconductor release. You can also userenv::init(bioconductor = TRUE) to initialize with thelatest-available release for the version of R being used.
Project settings can now be overridden by setting an R option ofthe same name. For example, one could force a project to useBioconductor 3.14 by settingoptions(renv.settings.bioconductor.version = "3.14") withinthe project.Rprofile (or similar startup Rprofile).
The ad-hoc package repository called “local sources” has beenrenamed to the “package cellar”. In addition, the path to the cellar isnow controlled by theRENV_PATHS_CELLAR environmentvariable, rather thanRENV_PATHS_LOCAL. This change wasmade to reduce confusion between “local sources” of packages locatedsomewhere on the filesystem, as opposed to packages explicitly placed inthis ad-hoc repository.RENV_PATHS_LOCAL remains supportedfor backwards compatibility.
TheRENV_PATHS_CELLAR environment variable can nowbe set to multiple paths. Use; as a separator betweenpaths; for example,RENV_PATHS_LOCAL=/path/to/sources/v1;/path/to/sources/v2.(#550)
Packages installed viae.g. renv::install("./path/to/package") will now retain therelative path to that package within the lockfile. (#873)
Fixed an issue where invalidconfig option valueswere not properly reported. (#773)
renv now supports restoration of packages installed via one ofther-universerepositories.
renv gains thebioconductor.version project setting,used to freeze the version of Bioconductor used in a particular project.When set, this will override any version that might be selected via theBiocManager package. (#864)
renv now infers that parameterized R Markdown documents have adependency on theshiny package. In addition, R codeincluded within theparams: list will be parsed fordependencies. (#859)
renv now ignores hidden directories during dependency discoveryby default. If you want to force a particular hidden directory to beincluded for discovery, you can use a.renvignore file withan explicit inclusion criteria; e.g. !.hidden/.
renv now supports the*release remotes specifier forGitHub repositories, for requesting installation of the latest declaredrelease of a package from GitHub. (#792)
renv now handles packages stored within the sub-directory of aGit repository better. (#793)
Fixed an issue whererenv::history() would fail toresolve the correct lockfile path if the working directory was changed.(#834)
Refined dependency discovery withinglue::glue()expressions.
renv now parses packages referenced via thebase_format field within an R Markdown document’s YAMLheader. (#854)
Fixed an issue where renv would fail to produce the appropriatebinary repository URL for RSPM repositories built using Red HatEnterprise Linux.
Fixed an issue whererenv::snapshot() could causethe environment name and / or path associated with a Python environmentto be omitted from the lockfile. (#843)
Fixed an issue whererenv::restore() could fail torestore packages which referred to their source via an explicit path intheSource field. (#849)
renv no longer requires explicit user consent when used withinSingularity containers. (#824,
renv now respects theR_PROFILE_USER environmentvariable, in addition to theuser.profile configurationoption, when considering whether the user.Rprofile shouldbe examined for package dependencies. (#821)
The renv auto-loader can now be disabled by setting theenvironment variableRENV_AUTOLOADER_ENABLED = FALSE. Thiscan be useful if you’d like to explicitly control how a project isloaded, e.g. by callingrenv::load() explicitly.
renv::snapshot() gains thereposargument, to be used to force the lockfile to be generated with therequested set of R repositories encoded within.
renv now validates that therepos option, as used byrenv::snapshot(), is a named vector. (#811)
Fixed an issue where renv’s shims, e.g. forinstall.packages(), failed to pass along other optionalarguments to the shimmed function correctly. (#808)
renv now usestools::R_user_dir() to resolve thedefault path to the global renv cache, for R installations 4.0.0 orgreater. If the renv cache still exists at the old location, thatlocation will be used instead. This change should only affect brand newinstallations of renv on newer versions ofR.
Fixed an issue with renv tests failing with R (>=4.2.0).
renv will no longer auto-activate itself within R processeslaunched viaR CMD INSTALL. This behavior can be controlledif necessary via theRENV_ACTIVATE_PROJECT environmentvariable – set this toTRUE to force the project in thecurrent working directory to be activated, andFALSE tosuppress the renv auto-loader altogether. (#804)
Added dependency discovery support for R utility scriptsidentified by a shebang line instead of a file extension. (#801;
Fixed an issue whererenv::install("<package>", type = "both") wouldattempt to install the package from sources, even if the current systemdid not have the requisite build tools available. (#800)
renv::scaffold() gains thesettingsargument, used to create a project scaffolding with some default projectoptions set. (#791)
renv now determines the default branch name for packagesinstalled from GitLab without an explicit reference supplied; forexample, as inrenv::install("gitlab::<user>/<repo>").(#795)
renv now infers a dependency on thebslib packagefor R Markdown documents using custom themes. (#790)
renv will now prompt users to activate the current project whencallingrenv::snapshot() orrenv::restore()from within a project that has not yet been activated. (#777)
renv now has improved handling forgit remotes.(#776;
renv::restore() gains theexcludeargument, used to exclude a subset of packages during restore.(#746)
Fixed an issue whererenv::dependencies() could failto parse dependencies in calls toglue::glue() that usedcustom open and close delimiters. (#772)
Fixed an issue whererenv::init(bare = TRUE) wouldunnecessarily scour the project for R package dependencies.(#771)
Fixed an issue where renv could fail to install packages locatedon GitHub within sub-subdirectories. (#759)
renv gains the functionembed(), used to embed alockfile with an R document (via a call torenv::use()).
renv::use() gains the lockfile argument. This can beuseful for R Markdown documents and scripts that you’d like to run withthe context for a particular lockfile applied.
renv::rebuild() gains thetypeparameter, for parity withrenv::install().
Fixed an issue where renv could incorrectly copy an incompatibleversion of an R package from a site library into the project libraryduring install. (#750)
renv::dependencies() can now parse (some) usages ofparsnip::set_engine().
renv::dependencies() now has improved handling forpiped expressions.
Fixed crash during dependency discovery when encounteringbox::use() declarations that use a trailing comma, and nolonger treat. and.. as package names. (
renv::clean() no longer attempts to clean the systemlibrary by default. (#737)
Fixed an issue whereinstall.packages() could failwhen used within an renv project to install a package from localsources. (#724)
The chunkrenv.ignore parameter can now be set toFALSE. When set, renv will explicitly parse dependenciesfrom chunks even if other chunk metadata would have told renv to ignoreit (e.g. because it was marked witheval=F).(#722)
Fixed an issue where chunks with the chunk optioneval=F would still be scanned for dependencies.(#421)
In interactive sessions,renv::use_python() will nowprompt for the version of Python to be used. Python installations in aset of common locations will be searched. See?renv::use_python() for more details.
Fixed an issue where renv would fail to retrieve packages fromthe archives if the lockfile entry was tagged with aRemoteSha field.
renv::restore() will now prefer restoring packagesfrom the repository named in theRepository field ifavailable. The name is matched against the repository names set in the Rrepos option, or as encoded in the renv lockfile.(#701)
renv now supports the discovery of dependencies withininterpolated strings as used by theglue package.
RENV_CONFIG_EXTERNAL_LIBRARIES can now be configuredto use multiple library paths, delimited by either:,;, or,. (#700)
renv gains the configuration option,exported.functions, controlling which functions and objectsare placed on the R search path when renv is attached (e.g. vialibrary(renv)). Set this toNULL to instructrenv not to place any functions on the search path. This helps avoidissues with, for example,renv::load() maskingbase::load(). When set, all usages of renv APIs must beexplicitly qualified with therenv:: prefix.
renv::install("user/repo/subdir with spaces") nowworks as expected. (#694)
renv can now parse package dependencies declared bytargets::tar_option_set(packages = <...>).(#698)
renv no longer performs an automatic snapshot following auser-canceled renv action – for example, ifrenv::restore()is canceled, the next automatic snapshot will be suppressed.(#697)
Added thevcs.ignore.local project setting, tocontrol whether the project’srenv/local folder is added torenv’s VCS ignore file (e.g. renv/.gitignore).(#696)
Fixed an issue where renv’s bootstrapping code couldinadvertently bootstrap with the wrong version of renv, if the sourceand binary versions of renv on CRAN were not in sync. (#695)
Fixed an issue whererenv::status() could provide amisleading message for packages which are recorded in the lockfile, butnot explicitly required by the project. (#684)
renv::clean() gains theactionsargument, allowing the caller to control which specific actions aretaken during aclean() operation.
renv no longer performs an automatic snapshot after a call torenv::status(). (#651)
Fixed an issue where attempts to transform RSPM repository URLscould fail if the copy of R was installed without a localCRAN_mirrors.csv file.
Fixed an issue whererenv::init() could fail whenpassed a relative path to a directory. (#673)
Fixed an issue whererenv::dependencies() would missdependencies in R Markdown YAML headers containing multiple outputformats. (#674)
renv::install() now better respects theRemotes field in a projectDESCRIPTION file,if available. (#670)
RENV_DOWNLOAD_METHOD is now treated as an alias forRENV_DOWNLOAD_FILE_METHOD.
Fixed an issue where renv would fail to load if the~/.Rprofile existed but was an empty file.
renv::snapshot() no longer creates anrenv/activate.R file in the project folder if one does notalready exist. (#655)
Therenv::hydrate() function gains theupdate argument, used to control whetherrenv::hydrate() chooses to update packages when invoked.When set toTRUE, if the version of a package installed inthe source library is newer than that of the project library, then renvwill copy that version of the package into the project library.(#647)
TheRENV_PATHS_PREFIX_AUTO environment variable cannow be set to instruct renv to include an OS-specific component as partof the library and cache paths. This is primarily useful for Linuxsystems, where one might want to share a global cache with multipledifferent operating systems. The path component is constructed from theID andVERSION_CODENAME /VERSION_ID components of the system’s/etc/os-release file.
renv’s dependency discovery machinery now has preliminary supportfor packages imported via thebox package;e.g. box::use(dplyr[...]).
Multiple cache paths can now be specified, with each cache pathseparated by either a; or:. This can beuseful when you’d like to use multiple package caches within the sameproject; for example, because you’d like to share a read-only cache witha set of projects. (#653,
Fixed an issue where renv could fail to discover dependencies indirectories with very large.gitignore or.renvignore files. (#652)
renv gains a new configuration option,install.shortcuts. When enabled, if renv discovers that apackage to be installed is already available in the user or sitelibraries, renv will instead install a copy of that package into theproject library. (#636)
renv gains a new function,renv::use(), used todownload, install, and load a set of packages directly within an Rscript.renv::use() can make it easier to share astandalone R script, with the packages required to install that scriptembedded directly in the script. It is inspired in part by thegroundhog package.
renv::install(".") can now be used to install apackage from sources within the current working directory.(#634)
Fixed an issue whererenv::update() could fail if apackage installed from GitHub was missing theRemoteHostfield in its DESCRIPTION file. (#632)
renv now has support for custom project profiles. Profiles can beused to activate different sets of project libraries + lockfiles fordifferent workflows in a given project. Seevignette("profiles", package = "renv") for moredetails.
Fixed an issue where attempts to initialize an renv project in apath containing non-ASCII characters could fail on Windows.(#629)
Fixed an issue whererenv::install("<package>") could fail if renv choseto install the package from MRAN rather than from one of the activepackage repositories. (#627)
renv again defaults to using the project’srenv/staging folder for staged / transactional installs.Use theRENV_PATHS_LIBRARY_STAGING environment variable ifmore granular control over the staging library path is required. Thisfixes issues on Windows with creating junction points to the globalpackage cache on Windows. (#584)
renv no longer skips downloading a requested source package if anexisting cached download exists and appears to be valid. This shouldhelp avoid issues when attempting to install a package whose associatedtarball has changed remotely. (#504)
During bootstrap, renv will now attempt to download and unpack abinary copy of renv if available from the specified packagerepositories.
renv now always attempts to bootstrap itself from the R Project’sCloud package repository, as a fallback in case no other repository isavailable. (#613)
renv::rebuild(<package>) now uses thelatest-available version of the requested package(s) if those packagesare not currently installed.
Fixed an issue whererenv::restore(library = "/path/to/lib") would fail torestore packages, if those packages were already installed on the activelibrary paths (as reported by.libPaths()). (#612)
renv::snapshot() gains thereprexargument. Set this toTRUE if you’d like to embed an renvlockfile as part of a reproducible example, as generated by thereprexpackage.
renv::status() now reports packages that arereferenced in a project’s scripts, but are neither installed in theproject library nor recorded in the lockfile. (#588)
Fixed an issue where package installation could fail if theconfigure.vars option was set to be a named character,rather than a named list. (#609)
renv now invalidates the available packages cache if thehttps_proxy environment variable changes. (#579)
renv::install(<pkg>) will now install thelatest-available version of that package from local sources, if thatpackage is available and newer than any package available on the activepackage repositories. (#591)
The configuration optionstartup.quiet has beenadded, allowing one to control whether renv will display the typicalstartup banner when a project is loaded.
renv now better handles being unloaded and reloaded within thesame R session. In particular, warnings related to a corrupted lazy-loaddatabase should no longer occur. (#600)
renv no longer reinstalls packages that are already installed andup-to-date in bare calls torenv::install().
renv now uses the R temporary directory for staging, whenperforming transactional restores / installs. If you need to control thepath used for staged installs, please set theRENV_PATHS_LIBRARY_STAGING environment variable.
Theinstall.verbose configuration option has beenadded. When set toTRUE, renv will stream the outputgenerated by R when performing a package installation. This can behelpful in some cases when diagnosing a failed restore / install.(#330)
Fixed an issue where renv could fail to parse R Markdown chunkheaders with an empty label. (#598)
The environment variableRENV_PATHS_LIBRARY_ROOT_ASIS can now be used to controlwhether the project name should be used as-is when forming the librarypath within theRENV_PATHS_LIBRARY_ROOT folder. Set this to"TRUE" if you would prefer renv did not append a uniqueidentifier to your project’s library path. (#593)
Fixed an issue where GitLab references were not URL encoded.(#590)
renv no longer emits warnings when parsing multi-mode R filesthat make use of re-used knitr chunks (those specified as<<label>>). (#586)
The library used for staged installs can now be configured viatheRENV_PATHS_LIBRARY_STAGING environment variable.(#584)
Fixed an issue where bootstrapping an older version of renv couldfail if the R repositories had not been appropriately set.
Fixed an issue whererenv::dependencies() could givean error if called with apath argument of length >1.
renv::restore() gains therebuildargument, allowing users to control whether packages should be rebuiltonrestore() rather than installed via links or copies fromthe cache, or other sources providing already-installedpackages.
renv will now attempt to bootstrap itself from CRAN, in additionto any repositories declared viagetOption("repos"). Ifyou’d prefer to disable this behavior, you can setoptions(renv.bootstrap.repos = character()).
The renv settingr.version has been added. This canbe set if you’d like to associate a particular project with a specificversion of R, independent of the version of R actually used whensubsequent lockfiles are created viarenv::snapshot(). Forexample, settingrenv::settings$r.version("4.0") willensure that R version"4.0" is encoded in the lockfile forfuture calls torenv::snapshot() in a project.(#254)
renv::dependencies() now detects the usage of Rpackages within dotfiles; e.g. the project.Rprofile.(#569)
renv::status() gains thecacheargument, used to control whetherrenv::status() alsoperforms diagnostics on the global package cache. (#570)
Fixed an issue whererenv::status() would make anun-necessary call torenv::dependencies(). (#570)
Fixed an issue whererenv::install("bioc::<package>", rebuild = TRUE)would fail to install the requested package. (#565)
Fixed an issue where the repository name for a package installedfrom an R package repository was sometimes incorrect. (#402)
WhenRENV_PATHS_LIBRARY_ROOT is set, renv will nowdisambiguate library paths based on a hash of the project’s path.(#564)
_R_CHECK_SUGGESTS_ONLY_=false.renv now ensures all of its dependencies are loaded eagerly whenrunning tests, to avoid issues with missing + lazily-loadedpackages.
renv::snapshot() now accepts library paths specifiedwith a relative path. (#562)
renv::snapshot() no longer excludes the projectitself, forR package projects that usegolem. (#538)
The renv configuration optioncache.symlinks can nowbe used to control whether renv used symlinks into the cache, as opposedto full package copies. Please see?renv::config for moredetails. (#556)
renv::snapshot() gains thepackagesargument, to be used when creating a lockfile that captures a specificset of packages and their dependencies. renv will use thecurrently-installed versions of those packages when determining thepackage records to be written to the lockfile. (#554)
renv::dependencies() now accepts an R function asthe first argument, for finding the packages used by a particularfunction. Currently, package usages must be prefixed with:: to be detected. (#554)
renv::record(<package>) now ensures that thelatest-available version of that package is recorded in the lockfile.Previously, a package record without any specified version was addedinstead. For existing records without a recorded version, thelatest-available version on the package repositories will be used duringrestore() instead. (#540)
renv now reads the default branch tagged for repositories createdon GitHub, ensuring that calls of the formrenv::install("<user>/<repo>") resolve to thedeclared default branch, rather than always defaulting to"master". (#557)
renv now only installs packages from sources if it detects thatbuild tools are available. This determination is done by checkingwhethermake is available on thePATH.(#552)
Warnings related to unknown sources can now be suppressed bysettingoptions(renv.warnings.unknown_sources = FALSE).(#546)
renv now ignores chunks with the parameterexercise=TRUE set, under the assumption that such chunksmight contain errors and so otherwise be un-parsable.
renv now warns if sandbox generation takes a long time (> 30seconds).
renv now provides an optional locking mechanism, to help minimizethe chance of interprocess conflicts when multiple R processes need touse the same renv project. The option is currently disabled by default;it can be enabled by settingoptions(renv.config.locking.enabled = TRUE) in anappropriate R startup file. (#525)
renv now uses R’s internal tar implementation by default onWindows. This is done to avoid issues that may occur when a version oftar.exe on thePATH exists, but does notaccept Windows-style paths. TheTAR environment variablecan be set if one needs to explicitly force the use of a particulartar.exe executable. (#521)
renv now prependsrenv (<version>) to the useragent string. This should help ensure that package binaries are locatedwhen installing packages from RSPM outside of RStudio. (#520)
renv now uses a task callback to detect mutations to the projectlibrary when theauto.snapshot configuration option isenabled. This will help ensure that automatic snapshots occur whenpackages are installed via a mechanism not explicitly understood byrenv. (#501)
renv now treats the user + site libraries as package sourcesduring a restore. If renv sees that a package already installed in oneof these libraries is compatible with the record requested viarenv::install() orrenv::restore(), that copyof the package will be copied and used. (#492)
renv now performs a lighter-weight check as to whether theproject lockfile is synchronized with the project library on load. Thedefault value for thesynchronized.check config option hasbeen changed back toTRUE. (#496)
renv now handles theremotes syntax for installingpackages lying within the sub-directory of a GitHub repository; that is,renv::install("user/repo/subdir") should work as expected.(#497)
Fixed an issue where renv did not construct the correct URL forpackages to be installed from Bitbucket remotes. (#494)
Fixed an issue where theRENV_PATHS_PREFIXenvironment variable was inappropriately normalized when renv wasloaded. (#465)
Fixed an issue whererenv::install(..., type = "binary") would still attempt toinstall packages from sources in some cases. (#461)
renv now always writesrenv/.gitignore, to ensurethat the appropriate directories are ignored for projects whichinitializegit after renv itself is initialized.(#462)
R Markdown documents with the.Rmarkdown fileextension are now parsed for dependencies.
Fixed an issue where setting theexternal.librariesconfiguration option would trigger a warning. (#452)
Improved handling of unicode paths on Windows. (#451)
renv::snapshot(project = <path>) now properlyrespects.gitignore /.renvignore files, evenwhen that project has not yet been explicitly initialized yet.(#439)
The default value of thesynchronized.check optionhas been changed from TRUE to FALSE.
Fixed an issue where packages downloaded from Bitbucket andGitLab did not record the associated commit hash.
Fixed an issue where attempting to install packages from GitLabcould fail to install the correct version of the package.(#436)
renv::snapshot() now preserves records in a lockfilethat are only available for a different operating system. This shouldmake it easier to share lockfiles that make use of platform-specificpackages. (#419)
renv better handles files that are removed during an invocationtorenv::dependencies(). (#429)
The configuration optioninstall.staged has beenrenamed toinstall.transactional, to better reflect itspurpose.install.staged remains supported as a deprecatedalias.
Fixed an issue where renv could fail to parse non-ASCII contenton Windows. (#421)
renv::update() gains theexcludeargument, useful in cases where one would like to update all packagesused in a project, except for a small subset of excluded packages.(#425)
renv::update() now respects the projectignored.packages setting. (#425)
Fixed an issue where RSPM binary URL transformations could failfor Ubuntu Trusty. (#423)
renv now records theOS_type reported in a package’sDESCRIPTION file (if any), and ignores packagesincompatible with the current operating system during restore.(#394)
renv::install() gains thetypeargument, used to control whether renv should attempt to installpackages from sources ("source") or using binaries("binary").
renv now knows how to find and activate Rtools40, for R 4.0.0installations on Windows.
TheRENV_PATHS_PREFIX environment variable can nowbe used to prepend an optional path component to the project library andglobal cache paths. This is primarily useful for users who want to sharethe renv cache across multiple operating systems on Linux, but need todisambigutate these paths according to the operating system in use. See?renv::paths for more details.
Fixed an issue whererenv::install() could fail forpackages from GitHub whose DESCRIPTION files contained Windows-styleline endings. (#408)
renv::update() now also checks and updates anyBioconductor packages used within a project. (#392)
renv now properly parses negated entries within a.gitignore; e.g.!script.R will indicate thatrenv should includescript.R when parsing dependencies.(#403)
Fixed an issue where packages which had only binaries availableon a package repository were not detected as being from a packagerepository. (#402)
Fixed an issue where calls of the formp_load(char = <vctr>) caused a failure whenenumerating dependencies. (#401)
Fixed an issue whererenv::install() could fail whenmultiple versions of a package are available from a single repository,but some versions of those packages are incompatible with the currentversion of R. (#252)
Fixed an issue where downloads could fail when the associatedpre-flight HEAD request failed as well. (#390)
Fixed an issue where empty records within a DESCRIPTION filecould causerenv::dependencies() to fail. (#382)
renv will now download binaries of older packages from MRAN whenpossible.
renv will now attempt to re-generate the system library sandboxif it is deleted while a session is active. (#361)
Fixed an issue where Python packages referenced usingreticulate::import() were incorrectly tagged as R packagedependencies. Similarly, renv now only considers calls tomodules::import() if those calls occur within a call tomodules::module(). (#359)
renv::scaffold() now also generates a lockfile wheninvoked. (#351)
The argumentconfirm has been renamed toprompt in all places where it is used.confirmremains supported for backwards compatibility, but is no longerexplicitly documented. (#347)
The continuous integration renv vignette now also contains atemplate for using renv together with GitLab CI. (#348,
renv now properly resets the session library paths when callingrenv::deactivate() from within RStudio. (#219)
renv::init() now restores the associated projectlibrary when called in a project containing a lockfile but no projectlibrary nor any pre-existing project infrastructure.
Fixed an issue on Windows where attempts to download packagesfrom package repositories referenced with afile:// schemecould fail.
The configuration optiondependency.errors has beenadded, controlling how errors are handled during dependency enumeration.This is used, for example, when enumerating dependencies during a calltorenv::snapshot(). By default, errors are reported, and(for interactive sessions) the user is prompted to continue.(#342)
renv::dependencies() gains two new arguments: theprogress argument controls whether renv reports progresswhile enumerating dependencies, anderrors controls howrenv handles and reports errors encountered during dependency discovery.Thequiet argument is now soft-deprecated, but continues tobe supported for backwards compatibility. Specifyingquiet = TRUE is equivalent to specifyingprogress = FALSE anderrors = "ignored".Please see the documentation in?dependencies for moredetails. (#342)
The environment variableRENV_PATHS_LIBRARY_ROOT cannow be set, to instruct renv to use a particular directory as a host forany project libraries that are used by renv. This can be useful forcertain cases where it is cumbersome to include the project librarywithin the project itself; for example, when developing an R package.(#345)
The code used to bootstrap renv (that is, the code used toinstall renv into a project) has been overhauled. (#344)
renv no longer unsets an error handler set within the userprofile when loading a project. (#343)
renv gains the “explicit” snapshot type, wherein only packagesexplicitly listed as dependencies within the projectDESCRIPTION file (and those package’s transitivedependencies) will enter the lockfile whenrenv::snapshot()is called. (#338)
renv will now transform RSPM source URLs into binary URLs asappropriate, allowing renv to use RSPM’s binary repositories duringrestore. See?config for more details. (#124)
renv will now infer a dependency onhexbin inprojects that make use of theggplot2::geom_hex()function.
renv now tries to place Rtools on the PATH when a package isinstalled with theinstall.packages() hook active.(#335)
Fixed an issue where attempts to specifyRENV_PATHS_RTOOLS would be ignored by renv. (#335)
Fixed an issue where downloads could fail when using thewininet downloader, typically with a message of the form“InternetOpenUrl failed: ‘The requested header was not found’”.
renv better handles projects containing special characters onWindows. (#334)
renv better handles unnamed repositories. (#333)
renv gains the config optionhydrate.libpaths,allowing one to control the library paths used by default forrenv::hydrate(). (#329)
renv::hydrate() gains thesourcesargument, used to control the library paths used by renv when hydratinga project. (#329)
renv now sandboxes the system library by default onWindows.
renv now validates that the Xcode license has been acceptedbefore attempting to install R packages from sources. (#296)
The R optionrenv.download.override can now be usedto override the machinery used by renv when downloading files. Forexample, settingoptions(renv.download.override = utils::download.file)would instruct renv to use R’s own downloader when downloading filesfrom the internet. This can be useful when configuration ofcurl is challenging or intractable in your environment, oryou’ve already configured the base R downloader suitably.
renv::use_python("~/path/to/python") now works asexpected.
renv now properly expandsR_LIBS_SITE andR_LIBS_USER when set within a startup.Renviron file. (#318)
Therenv.download.headers option can now be used toprovide arbitrary HTTP headers when downloading files. See theAuthentication section invignette("renv")for more details. (#307)
renv gains the project settingpackage.dependency.fields, for controlling which fields inan R package’sDESCRIPTION file are examined whendiscovering recursive package dependencies. This can be useful whenyou’d like to instruct renv to track, for example, theSuggests dependencies of the packages used in your project.(#315)
renv now better handles repositories referenced using fileURIs.
Packages installed from GitHub usingrenv::install()will now also haveGithub* fields added, in addition to thedefaultRemote* fields. This should help fix issues whenattempting to deploy projects to RStudio Connect requiring packagesinstalled by renv. (#397)
renv now prefers using a RemoteType field (if any) whenattempting to determine a package’s source. (#306)
renv gains a new functionrenv::scaffold(), forgenerating renv project infrastructure without explicitly loading theproject. (#303)
renv now updates its local.gitignore file, whenpart of a git repository whose git root lives in a parent directory.(#300)
find on Solaris.cp on Solaris.renv gains a new functionrenv::record(), forrecording new packages within an existing lockfile. This can be usefulwhen one or more of the recorded packages need to be modified for somereason.
An empty.renvignore no longer erroneously ignoresall files within a directory. (#286)
renv now warns if the version of renv loaded within a projectdoes not match the version declared within the renv autoloader.(#285)
renv gains a new functionrenv::run(), for running Rscripts within a particular project’s context inside an R subprocess.(#126)
The algorithm used by renv for hashing packages has changed.Consider usingrenv::rehash() to migrate packages from theold renv cache to the new renv cache.
renv::status() now reports packages which arereferenced in your project code, but are not currently installed.(#271)
renv is now able to restore packages with a recorded URL remote.(#272)
renv::dependencies() can now parse R packagedependencies used as custom site generator in an Rmd yaml header. (#269,@cderv)
renv now properly respects a downloader requested by theenvironment variableRENV_DOWNLOAD_FILE_METHOD.
renv no longer sources the user profile (normally located at~/.Rprofile) by default. If you desire this behavior, youcan opt-in by settingRENV_CONFIG_USER_PROFILE = TRUE;e.g. within your project or user.Renviron file.(#261)
renv::restore() gains thepackagesargument, to be used to restore a subset of packages recorded within thelockfile. (#260)
renv now tries harder to preserve the existing structure ininfrastructure files (e.g. the project.Rprofile) that itmodifies. (#259)
renv now warns if any Bioconductor packages used in the projectappear to be from a different Bioconductor release than the onecurrently active and stored in the lockfile. (#244)
renv now normalizes any paths set in theRENV_PATHS_* family of environment variables when renv isloaded.
Fixed an issue where renv would not properly clean up after afailed attempt to callSys.junction(). (#251)
Fixed an issue where renv would, in some cases, copy rather thanlink from the package cache when the library path had been customizedwith theRENV_PATHS_LIBRARY environment variable.(#245)
The method renv uses when copying directories can now becustomized. When copying directories, renv now by default usesrobocopy on Windows, andcp on Unix. Thisshould improve robustness when attempting to copy files in somecontexts; e.g. when copying across network shares.
renv now tracks the version of Bioconductor used within a project(if applicable), and uses that when retrieving the set of repositoriesto be used duringrenv::restore().
renv::dependencies() can now parse R packagedependencies declared and used by themodules package.(#238,
Fixed an issue whererenv::restore() could fail inDocker environments, usually with an error message like ‘Invalidcross-device link’. (#243)
renv::install() disables staged package install whenrunning with the Windows Subsystem for Linux. (#239)
renv::dependencies() gains a new argumentdev, indicating whether development dependencies shouldalso be included in the set of discovered package dependencies. Bydefault, only runtime dependencies will be reported.
renv has gained the functionrenv::diagnostics(),which can occasionally be useful in understanding and diagnosing renv(mis)behaviors.
renv::equip() can now be used on macOS to installthe R LLVM toolchain normally used when compiling packages from source.renv will also use this toolchain as appropriate when building packagesfrom source.
renv::install() now provides a custom Makevars whenbuilding packages on macOS with Apple Clang, to avoid issues due to theuse of ‘-fopenmp’ during compilation.
renv::install() now respects explicit versionrequests when discovered in a project’s DESCRIPTION file.(#233)
Fixed an issue whererenv:::actions() would fail toreport any actions if the project lockfile was empty. (#232)
When using renv for R package development, renv will no longerattempt to write the package being developed to the lockfile.(#231)
Fixes for checks run on CRAN.
renv will now search for Rtools in more locations.(#225)
renv::load() now ensures that the version of renvassociated with the loaded project is loaded when possible. In addition,experimental support for switching between projects withrenv::load() has been implemented. (#229)
renv::dependencies() no longer treats folders namedwith the extension.Rmd as though they were regular files.(#228)
It is now possible to install source packages contained within.zip archives usingrenv::install().
Fixed an issue where attempts to callrenv::restore() with the path to the lockfile explicitlyprovided would fail. (#227)