r-hub/sysreqs

Error: Failed to install 'unknown package' from GitHub

laresbernardo opened this issue · 5 comments

Hi! From one day to another I started getting this error on my github actions for R-CMD check.

Run Rscript -e "remotes::install_github('r-hub/sysreqs')"
  Rscript -e "remotes::install_github('r-hub/sysreqs')"
  sysreqs=$(Rscript -e "cat(sysreqs::sysreq_commands('DESCRIPTION'))")
  sudo -s eval "$sysreqs"
  shell: /bin/bash -e {0}
  env:
    R_REMOTES_NO_ERRORS_FROM_WARNINGS: true
    _R_CHECK_FORCE_SUGGESTS_: false
    _R_CHECK_dontrun_EXAMPLES_: false
    RSPM: https://packagemanager.rstudio.com/cran/__linux__/xenial/latest
    R_LIBS_USER: /home/runner/work/_temp/Library
    TZ: UTC
    _R_CHECK_SYSTEM_CLOCK_: FALSE
    NOT_CRAN: true
    RHUB_PLATFORM: linux-x86_64-ubuntu-gcc
Using bundled GitHub PAT. Please add your own PAT to the env var `GITHUB_PAT`
Error: Error: Failed to install 'unknown package' from GitHub:
  cannot open URL 'https://api.github.com/repos/r-hub/sysreqs/contents/DESCRIPTION?ref=HEAD'
Execution halted
Error: Process completed with exit code 1.

Any idea why? Thanks!

Error: Error: Failed to install 'unknown package' from GitHub:
  cannot open URL 'https://api.github.com/repos/r-hub/sysreqs/contents/DESCRIPTION?ref=HEAD'
Execution halted
Error: Process completed with exit code 1.

This seems like a network failure, or maybe GitHub API rate limiting failure.

@laresbernardo This started happening to me too recently. Fixed it by changing the GA yaml file to

      - name: Install system dependencies
        if: runner.os == 'Linux'
        run: |
          while read -r cmd
          do
            eval sudo $cmd
          done < <(Rscript -e 'writeLines(remotes::system_requirements("ubuntu", "16.04"))')

following the dplyr repo example.

@bpbond thanks for sharing your solution. It did not solve the issue for me though. I found this fix instead in the RStudio community forum. Worked for me here. I hope this can help others...

Good to know—thanks.