You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The tests workflow on main has been failing on the macos-15, aarch64-apple-darwin matrix legs (run 25882534028, and earlier run 25867121979 closed as transient in #5886). Same shape both times — after Swatinem/rust-cache@v2 restores its cache, /Users/runner/.cargo/bin/cargo resolves to rustup-init (the installer) instead of the rustup proxy, so every subsequent cargo invocation dies with:
error: error: unexpected argument 'build' found
Usage: rustup-init[EXE] [OPTIONS]
Root cause is upstream and not transient: Swatinem/rust-cache#341 ("cache-bin: true breaks cargo subcommands on new github macos runner"), filed 2026-05-13 against a new macos-15 runner image rollout (actions/runner-images#14037). The fix the upstream issue documents is cache-bin: "false".
Solution
Set cache-bin: "false" on every Swatinem/rust-cache@v2 invocation in the repo (11 sites across workflows and composite actions). This stops ~/.cargo/bin/ from being restored from cache, so the rustup-managed cargo/rustc symlinks installed by the prior rustup target add step survive intact.
This loses nothing in practice — none of our workflows install cargo subcommands to ~/.cargo/bin/. baptiste0928/cargo-install already uses a custom root (/Users/runner/.cargo-install/...) with its own cache, so cargo-insta, cargo-nextest, wasm-pack, mdbook, etc. are unaffected.
Applying it everywhere (not just the failing macos legs) keeps the configuration consistent and protects the Linux/Windows legs from the same issue if the bug surfaces on other runner images.
Testing
Can't reproduce locally (the bug needs a macos-15 runner). The fix is the workaround documented in the upstream issue, and matches what the reporter confirmed unblocked their jobs. CI on this PR will verify the macos legs pass.
The new macos-15 runner image causes Swatinem/rust-cache@v2 to restore
a corrupted ~/.cargo/bin/cargo (resolves to rustup-init instead of the
rustup proxy), breaking every subsequent cargo invocation with
'error: unexpected argument <subcommand> found / Usage: rustup-init'.
Upstream-tracked at Swatinem/rust-cache#341
with the workaround being cache-bin: false. Apply it to every
rust-cache invocation in the repo so the bin directory is never
restored from cache.
Co-Authored-By: Claude <noreply@anthropic.com>
Three ubuntu-24.04 rust-cache sites in tests.yaml were missed in the
initial pass (check-links-book, measure-code-cov, test-deps-min-versions).
The bug currently only fires on macos-15, but the PR's stated intent is
to disable cache-bin everywhere for consistency.
Co-Authored-By: Claude <noreply@anthropic.com>
The same failure recurred on the next push to main: run 25886221899 on commit 815cbd1 — identical shape on build-prqlc-c (macos-15, aarch64-apple-darwin, default,test-dbs), cargo resolving to rustup-init after the rust-cache restore. Just bumping the failure count, no other action needed — this PR's fix still applies as-is.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The
testsworkflow on main has been failing on themacos-15, aarch64-apple-darwinmatrix legs (run 25882534028, and earlier run 25867121979 closed as transient in #5886). Same shape both times — afterSwatinem/rust-cache@v2restores its cache,/Users/runner/.cargo/bin/cargoresolves torustup-init(the installer) instead of the rustup proxy, so every subsequent cargo invocation dies with:Root cause is upstream and not transient: Swatinem/rust-cache#341 ("
cache-bin: truebreaks cargo subcommands on new github macos runner"), filed 2026-05-13 against a new macos-15 runner image rollout (actions/runner-images#14037). The fix the upstream issue documents iscache-bin: "false".Solution
Set
cache-bin: "false"on everySwatinem/rust-cache@v2invocation in the repo (11 sites across workflows and composite actions). This stops~/.cargo/bin/from being restored from cache, so the rustup-managedcargo/rustcsymlinks installed by the priorrustup target addstep survive intact.This loses nothing in practice — none of our workflows install cargo subcommands to
~/.cargo/bin/.baptiste0928/cargo-installalready uses a custom root (/Users/runner/.cargo-install/...) with its own cache, socargo-insta,cargo-nextest,wasm-pack,mdbook, etc. are unaffected.Applying it everywhere (not just the failing macos legs) keeps the configuration consistent and protects the Linux/Windows legs from the same issue if the bug surfaces on other runner images.
Testing
Can't reproduce locally (the bug needs a macos-15 runner). The fix is the workaround documented in the upstream issue, and matches what the reporter confirmed unblocked their jobs. CI on this PR will verify the macos legs pass.
Automated fix for failed run 25882534028.