Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue with R update to 4.4 #45

Closed
abigailkeller opened this issue May 8, 2024 · 8 comments · Fixed by #47
Closed

Issue with R update to 4.4 #45

abigailkeller opened this issue May 8, 2024 · 8 comments · Fixed by #47

Comments

@abigailkeller
Copy link

My R package was passing the pkgcheck action before the recent R update to 4.4 and now no longer passes (see github action here with the pass, and github action here a few days after the update where it no longer passes).

The pkgcheck action fails within 2 minutes with the following error:

` Error:
! error in pak subprocess
Caused by error:
! Could not solve package dependencies:

  • local::.: Can't install dependency ggplot2
  • ggplot2: Can't install dependency MASS
  • MASS: Needs R >= 4.4.0
  • MASS: Needs R >= 4.5

Backtrace:

  1. pak::lockfile_create("local::.", lockfile = ".pkgcheck/pkg.lock", …
  2. pak:::remote(function(...) { …
  3. err$throw(res$error)

Subprocess backtrace:

  1. base::withCallingHandlers(cli_message = function(msg) { …
  2. get("lockfile_create_internal", asNamespace("pak"))(...)
  3. prop$stop_for_solution_error()
  4. private$plan$stop_for_solve_error()
  5. pkgdepends:::pkgplan_stop_for_solve_error(self, private)
  6. base::throw(new_error("Could not solve package dependencies:\n", msg, …
  7. | base::signalCondition(cond)
  8. global (function (e) …
    Execution halted
    Ran 1/1 deferred expressions`

The error is coming from a dependency issue with MASS (which requires R 4.5?). Is there a way to edit my yaml file to solve this issue? This file was taken from an ROpenSci blog post.

@assignUser
Copy link
Collaborator

Hey, thanks for the report. This is a mismatch between the installed R version and the Matrix package requiring R>4.4
(see ropensci-review-tools/pkgcheck#199)
You can fix it by adding the following step to explicitly install 4.4
- uses: r-lib/actions/setup-r@v2

@abigailkeller
Copy link
Author

@assignUser Gotcha, thanks for your quick response and those resources! I'm still getting the same error with the following yaml, so I might just wait until Github catches up on R4.4. Thanks!

`name: pkgcheck

This will cancel running jobs once a new run is triggered

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref }}
cancel-in-progress: true

on:

Manually trigger the Action under Actions/pkgcheck

workflow_dispatch:

Run on every push to main

push:
branches:
- main
- master

jobs:
pkgcheck:
runs-on: ubuntu-latest
permissions:
issues: write
steps:
- uses: r-lib/actions/setup-r@v2
- shell: Rscript {0}
run: |
if (!requireNamespace("MASS", quietly = TRUE))
install.packages("MASS")
library(MASS)
- uses: ropensci-review-tools/pkgcheck-action@main`

@mpadge
Copy link
Member

mpadge commented May 9, 2024

@assignUser I think latest R on GH runners will remain 4.3 until their own listed versions like here are updated. So install-r still resolves to 4.3 and causes probs (although i haven't confirmed that)

@assignUser
Copy link
Collaborator

Oh yeah, I meant that in general not for this specific issue. Sorry for the confusion.

@assignUser
Copy link
Collaborator

@abigailkeller The issue is that our docker containers are not being rebuild due to {goodpractice} having been archived, sorry for the inconvenience.

@abigailkeller
Copy link
Author

@assignUser No worries! I'm nearly ready to submit my package to ROpenSci's statistical software review, and I'm wondering if I should wait until this issue is resolved before submitting? I'm not in a particular rush.

@assignUser
Copy link
Collaborator

@abigailkeller This should now be resolved! Please let us know if it's still not working!

@mpadge
Copy link
Member

mpadge commented May 15, 2024

I'm just going to re-open this as a reminder for us to remove those lines and revert to R4.4 once everything has settled down.

@mpadge mpadge reopened this May 15, 2024
@mpadge mpadge closed this as completed in fbf8305 May 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants