actions / runner-images

GitHub Actions runner images
MIT License
9.12k stars 2.82k forks source link

Cargo lo longer available on macOS-latest #9732

Closed francisdb closed 1 week ago

francisdb commented 1 week ago

Description

Since somewhere the past 4 days rust no longer is available on the macOS-latest images. Looks like there was a switch from macos-12 to macos-14-arm64

Runner Image
  Image: macos-14-arm64
  Version: 20240422.3
  Included Software: https://github.com/actions/runner-images/blob/macos-14-arm64/20240422.3/images/macos/macos-14-arm64-Readme.md
  Image Release: https://github.com/actions/runner-images/releases/tag/macos-14-arm64%2F20240422.3

image

https://github.com/francisdb/vpxtool/actions/runs/8805372288/job/24167793335

Previous build from 4 days ago

Runner Image
  Image: macos-12
  Version: 20240412.2
  Included Software: https://github.com/actions/runner-images/blob/macOS-12/20240412.2/images/macos/macos-12-Readme.md
  Image Release: https://github.com/actions/runner-images/releases/tag/macOS-12%2F20240412.2

https://github.com/francisdb/vpxtool/actions/runs/8753067182/job/24021993766

Platforms affected

Runner images affected

Image version and build link

20240422.3

https://github.com/francisdb/vpxtool/actions/runs/8805372288/job/24167793335

Is it regression?

yes

Expected behavior

cargo still works as before

Actual behavior

cargo: command not found

Repro steps

See linked repo

Alexey-Ayupov commented 1 week ago

Hello @francisdb. Indeed we are currently in the process of macos-14 to macos-latest migration, however the cargo should be there. We will check it.

Alexey-Ayupov commented 1 week ago

@francisdb, at least the cargo --version command works. Could you please specify macos-14 label and try again? Make sure that image version is 20240422.3

image

francisdb commented 1 week ago

I'm getting arm-64 Version: 20240415.6 when using macOS-14

https://github.com/francisdb/vpin/actions/runs/8813246540/job/24190584925?pr=67

Alexey-Ayupov commented 1 week ago

Yes, that's expected. We are in the middle of the updating images to the new version.

francisdb commented 1 week ago

According to https://github.com/actions/runner-images/discussions/3464 I can't pin a version so I can't try macos-14?

Alexey-Ayupov commented 1 week ago

I have forked your repository and run your workflow with macOS-14 label. And it works - https://github.com/Alexey-Ayupov/vpin/actions/runs/8815461877/job/24197473679.

Could you please clean your cash and try again today evening or tomorrow?

Planned end of the image version updating is today evening, so tomorrow all macOS 14 arm64 images should have version 20240422.3

francisdb commented 1 week ago

Looks like this is fixed now, maybe related to the cache clear

str4d commented 1 week ago

I encountered the same issue. The cause is that macos-latest used to point to macos-12 which is x86_64, but now points to macos-14 which is ARM64. This breaks the Cargo cache because the platform arch is unexpectedly different (and indeed deleting any caches that match the macOS runners is sufficient to fix the workflow).

I don't know what guarantees GitHub makes about the *-latest runner labels, but given that until now every *-latest runner was x86_64, this seems like a rather frustrating change for the ecosystem (though necessary).

Fernthedev commented 1 week ago

I don't know what guarantees GitHub makes about the *-latest runner labels, but given that until now every *-latest runner was x86_64, this seems like a rather frustrating change for the ecosystem (though necessary).

I wholeheartedly agree with this. I suffered from this issue today and was frustrated to find my CI action failing without any notice or ideas as to why. I'd appreciate if there could be some warning during the migration period notifying users that their cache is currently broken and/or a fix for the cache issue.

Glad to see the issue has a fix though, thanks!