fix(ci): global sccache cache tag + tolerate zero-test filters#4295
Conversation
Two regressions surfaced by tooling-only PRs (a PR that only touches xtask, like the cargo-deny workflow port): - The nextest package filter narrows an xtask-only change to `rdeps(=xtask)`, which selects zero tests; nextest's default then exits with `error: no tests to run`. Add `--no-tests=pass` so an empty selection is success — a tooling change legitimately affects no tests. - A new branch's Namespace cache starts cold: the volume is scoped per-branch and check/test never run on `main`, so there's no default-branch cache to inherit. Pin an explicit `sccache-ci` cache tag on the check/test runner so every branch reads/writes one global volume, the way the old shared S3 sccache bucket did. sccache entries are content-addressed, so concurrent writers can't corrupt each other — worst case is an occasional miss that recompiles. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (6)
📝 WalkthroughSummary by CodeRabbit
WalkthroughThe pull request makes two independent CI changes. First, it introduces a 🚥 Pre-merge checks | ✅ 4✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Fixes two CI regressions exposed by tooling-only PRs (a PR that only touches
xtask, e.g. #4294's cargo-deny port).1.
testfails with "no tests to run" on tooling-only PRsThe nextest package filter narrows an xtask-only change to
rdeps(=xtask), which selects zero tests — and nextest's default exitserror: no tests to run(exit 4). Add--no-tests=passso an empty selection is a pass; a tooling change legitimately affects no tests.2. New branches start with a cold cache
The Namespace cache volume is scoped per branch, and check/test only run on
pull_request(never onmain), so a fresh branch has no default-branch cache to inherit and recompiles the whole workspace from scratch (~5–6 min).Pin an explicit
sccache-cicache tag on the check/test runner (runs-on: namespace-profile-linux-rust-ci;overrides.cache-tag=sccache-ci) so every branch reads/writes one global volume — the way the old shared S3 sccache bucket did. sccache entries are content-addressed, so concurrent writers can't corrupt each other; worst case is an occasional miss that recompiles.Regenerate:
cargo x workflowsfromrust/cloud-storage(--checkverifies sync).🤖 Generated with Claude Code