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

setup-r not working on macos-13 runners #810

Closed
grimbough opened this issue Mar 20, 2024 · 5 comments
Closed

setup-r not working on macos-13 runners #810

grimbough opened this issue Mar 20, 2024 · 5 comments
Labels
bug an unexpected problem or unintended behavior

Comments

@grimbough
Copy link

Describe the bug

I'm currently unable to use the setup-r action on macos-13 runners. It fails at the "Downloading macOS utils" step with the error:

Error: Failed to get R devel: Failed to get R 4.4.0: Failed to install qpdf: Error: The process '/usr/local/bin/brew' failed with exit code 1

To Reproduce

A link to a failed run of the action can be found at: https://github.com/grimbough/test-workflow/actions/runs/8358075235/job/22878572700

The fairly minimal workflow file is:

on:
  workflow_dispatch:
  
name: Quick tests of setup-r action

env:
  GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}

jobs:

  testing:
    name: Test setup-r action
    runs-on: macos-13
    steps:    
      - name: Setup R
        uses: r-lib/actions/setup-r@v2

Expected behavior

The action seems to work fine on the GitHub runners using other MacOS version and it's be great to restore that behaviour on macos-13.

Additional context

I've noticed that the GitHub runner macos-13 base image has changed a bit recently e.g. there's no existing installation of R on there any more (actions/runner-images@7535fb5). Perhaps those recent changes are releated to this issue.

@grimbough grimbough added the bug an unexpected problem or unintended behavior label Mar 20, 2024
@gaborcsardi
Copy link
Member

This is a bug in homebrew, add

    env:
      HOMEBREW_NO_INSTALLED_DEPENDENTS_CHECK: true

to your workflow, to the setup-r step or the whole job.

@gaborcsardi
Copy link
Member

gaborcsardi commented Mar 20, 2024

Most probably it'll also go away when GitHub rolls out a runner image with a more recent homebrew installation. The macos-13 images hasn't been updated for about 50 days now:

Image Version: 20240204.1

https://github.com/actions/runner-images/blob/main/images/macos/macos-13-Readme.md

gaborcsardi added a commit that referenced this issue Mar 20, 2024
On macOS to avoid lengthy homebrew updates that are most probably
not needed. See #810 for an example failure.
@gaborcsardi
Copy link
Member

Added that env var to @v2 so it should work now.

@grimbough
Copy link
Author

Thanks for the super speedy response. That does seem to have resolved the issue, and has the nice effect of also reducing the runtime from > 7 minutes to < 1 minute.

Copy link

github-actions bot commented Apr 4, 2024

This issue has been automatically locked. If you believe you have found a related problem, please file a new issue and include a link to this issue

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 4, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug an unexpected problem or unintended behavior
Projects
None yet
Development

No branches or pull requests

2 participants