Packages with implict R version deps #31

Open
opened 2025-06-13 08:41:52 +00:00 by pat-s · 0 comments
Owner

Problem

Some packages depend on packages that have an explicit R version dep (e.g. {MASS} or {Matrix} requiring > 4.4 currently).

When installing such packages for < $R_VERSION, the install will fail as the dependency cannot be installed for this R version due to its constraint.

Effect

However, because we have the package listed in the index, R actually throws a hard error because it tries to install it:

Installing ACSSpack
Error:                                                                     
! error in pak subprocess
Caused by error: 
! Could not solve package dependencies:
* ACSSpack: Can't install dependency MASS (>= 7.3-60)
* MASS: Needs R >= 4.4.0
Type .Last.error to see the more details.

When trying this in vanilla R with a source repository, there is only a warning:

package 'ACSSpack' is not available for this version of R

Resolution

Because we don't have explicit package index files for every R version but just one (containing entries for all CRAN packages), this might just be like that.

## Problem Some packages depend on packages that have an explicit R version dep (e.g. {MASS} or {Matrix} requiring > 4.4 currently). When installing such packages for < `$R_VERSION`, the install will fail as the dependency cannot be installed for this R version due to its constraint. ## Effect However, because we have the package listed in the index, R actually throws a hard error because it tries to install it: ``` Installing ACSSpack Error: ! error in pak subprocess Caused by error: ! Could not solve package dependencies: * ACSSpack: Can't install dependency MASS (>= 7.3-60) * MASS: Needs R >= 4.4.0 Type .Last.error to see the more details. ``` When trying this in vanilla R with a source repository, there is only a warning: ``` package 'ACSSpack' is not available for this version of R ``` ## Resolution Because we don't have explicit package index files for every R version but just one (containing entries for all CRAN packages), this might just be like that.
Sign in to join this conversation.
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
devxy/build-cran-binaries#31
No description provided.