Repository navigation
fix(ci): [#3019] build without sccache when its server does not start - #3040
Conversation
Add the local composite action .github/actions/enable-sccache and use it in the nine Enable sccache steps. It starts the sccache server with the GitHub Actions cache backend and no idle timeout, and sets RUSTC_WRAPPER only when the server started. Otherwise the job builds without the cache and shows a warning annotation instead of failing. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…lback Co-Authored-By: Claude Opus 5.5 <[email protected]>
…e sccache startup fallback Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ay draft PRs Co-Authored-By: Claude Opus 5.5 <[email protected]>
…the sccache startup fallback Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
No actionable comments were generated in the recent review. Walkthrough
Merge Risk:
|
[Medium impact] The PR appears safe to merge; no blocking issues were found. SummaryThis PR adds a shared action that enables
Reviews (2) · Last reviewed commit: "docs(issues): [#3019] record the normal ..." · Reviewed by Greptile |
|
ACK 2cde16f |
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
ACK 6ef7064 |
da2ce7
left a comment
There was a problem hiding this comment.
Reviewed at 6ef706444788cf4bf2dd634586e682f9ada86321. Recomputed from the bytes at this head, against the merge base aea341d40; git merge-tree against develop d89ab84bd is clean: no conflicts, and no path is changed on both sides.
Process: a CI fix with an ADR amendment and spec updates, governed by implement-workflow, create-adr, create-issue and open-pull-request. The adapter stays thin (one if/else), the amendment section has precedent in another root ADR, the index row still holds, and the spec frontmatter fits the issue profile.
The change against its claim: the action starts the server with the cache backend in its step env:, exports the wrapper, backend and idle-timeout variables only on success, warns otherwise, and writes CARGO_INCREMENTAL=0 either way. All nine old steps (2 testing, 1 os-compatibility, 2 db-compatibility, 1 coverage, 3 db-benchmarking) are replaced and none is left; every job checks out before the local uses:; the docker-e2e if: is kept; both path-filtered workflows list the action under push and pull_request, and the rest only ignore Markdown. The V5 hit rates recompute as hits/(hits+misses+errors) in all 17 rows, one per job that ran the action.
Consistency: relative links and related-artifacts paths resolve; no dictionary words are added; nothing moves.
Hygiene: six commits with Conventional subjects carrying [#3019]; author = committer; the one body matches its diff and the other five are subject-only; each commit has one attribution footer, which no rule in the tree forbids. git diff --check is clean, the commit-id check prints nothing, and the only closing keyword is Closes #3019 in the description, for the issue this PR implements.
Findings: F1 to F3, all Nit; none blocks.
Checked, no finding: coverage already had CARGO_INCREMENTAL=0 in its job env; shell: bash covers the windows-latest jobs; the longest action line (151) is under the yamllint limit (200); docker-e2e gets a hosted runner here only on dependency-update branch pushes, as the spec says; V6 and AC2/AC3 are disclosed as post-merge work.
Checks
On the loop's compute node at this head, against the merge base aea341d40 (receipt server-gates-kranich-1421): the repository's pre-commit gate and lint roster exit 0 (509 s wall). This pull request has no review audit record, so there was nothing for the audit validator to check. The PR changes CI workflows, a composite action and documentation, so no package tests apply; the workflows themselves are exercised only by the hosted runs. Checked against the bytes at posting: .github/workflows/os-compatibility.yaml:28-30 sets a matrix of three operating systems by two toolchains, and its enable-sccache step (line 46) therefore runs in six jobs, not the three that ISSUE.md:234 records, as F1 says. The head was confirmed with git ls-remote before posting. GitHub checks at this head at posting time: "Publish (Development): completed/skipped; Publish (Release): completed/skipped; Context: completed/success; Package Coverage (${{ matrix.package }}): completed/skipped; Package Coverage Regression: completed/success; Persistence Benchmark PostgreSQL: completed/success; Persistence Benchmark MySQL: completed/success; Persistence Benchmark SQLite3: completed/success; Test (Docker) (release): completed/success; Docker E2E: completed/skipped; Unit (nightly): completed/success; Layer Boundary Bans: completed/success; Workspace Packaging: completed/success; Unit (stable): completed/success; Source Locations: completed/success; Documented Clippy Allows: completed/success; Shipped Features: completed/success; Database Compatibility MySQL (8.0): completed/success; Database Compatibility MySQL (8.4): completed/success; Database Compatibility PostgreSQL (15): completed/success; Database Compatibility PostgreSQL (14): completed/success; Database Compatibility PostgreSQL (17): completed/success; Database Compatibility PostgreSQL (16): completed/success; Discover Package Coverage: completed/success; Docs Lint: completed/success; Generate Coverage Report: completed/success; Build on windows-latest (stable): completed/success; Build on macos-latest (nightly): completed/success; Build on ubuntu-latest (stable): completed/success; Build on macos-latest (stable): completed/success; Build on ubuntu-latest (nightly): completed/success; Build on windows-latest (nightly): completed/success; CodeRabbit: completed/success; Greptile Review: completed/success". At posting, develop is d89ab84bd.
| verification branches and cover `docker-e2e` and `coverage` (V6) | ||
| - 2026-11-24 13:07 UTC - Claude Code (Claude Opus 5.5) - Spec PR #3020 merged. Added the | ||
| `enable-sccache` composite action, used it in the nine `Enable sccache` steps (the spec said | ||
| ten; the `os-compatibility.yaml` matrix makes one step run in three jobs), and amended the |
There was a problem hiding this comment.
[Nit][F1] The os-compatibility.yaml matrix runs the step in six jobs, not three.
os-compatibility.yaml:29-30 is os: [ubuntu-latest, macos-latest, windows-latest] by toolchain: [nightly, stable], and this PR's V5 table lists six Build on ... jobs. The aside means to explain the earlier count of ten, but as written it misstates the matrix. Suggest "runs in six matrix jobs", or dropping the aside.
| github-issue: 3019 | ||
| spec-path: docs/issues/open/3019-ci-sccache-startup-fallback/ISSUE.md | ||
| branch: "3019-ci-sccache-startup-fallback-spec" | ||
| branch: "3019-ci-sccache-startup-fallback" |
There was a problem hiding this comment.
[Nit][F2] The frontmatter lags the PR: related-pr on the next line is still null.
The progress log (line 244) and V5 record this PR as the spec's implementation run, and other in-progress open specs set the field to their implementation PR (2798-... to 2811, 2902-... to 3009). The linter all criterion (line 258) also stays unchecked, although the description reports linter all passing. Suggest related-pr: 3040, and ticking the criterion if it holds.
| - When the server starts, it exports `RUSTC_WRAPPER=sccache`, `SCCACHE_GHA_ENABLED=true` and | ||
| `SCCACHE_IDLE_TIMEOUT=0`. With no idle timeout the server lives for the whole job, so no later | ||
| compile starts a new server without this check. | ||
| - When the server does not start, it stops any server that may still come up late, exports |
There was a problem hiding this comment.
[Nit][F3] "stops any server that may still come up late" promises more than the step does.
The action calls sccache --stop-server || true once, right after the failed start (.github/actions/enable-sccache/action.yml:33). That call reaches a server only if it is already listening; nothing in the step stops a server that becomes ready afterwards. The effect is benign because RUSTC_WRAPPER is not exported, but the record overstates the guarantee. The spec's Server lifetime bullet (line 132) and the description say the same. Suggest "stops a server that is already listening", or cite the sccache behaviour that covers a later one.
|
ACK 6ef7064 — the composite action replaces all nine sccache enable steps with a checked server start and a warning fallback, and the workflow, ADR and spec claims recompute at this head apart from three non-blocking Nits |
…ssues/closed 4ac24bb docs(pr-reviews): [#3019] record the Greptile review round of PR 3046 (josecelano-bot) 8339a20 docs(issues): [#3019] keep T6b open until the post-merge runs show cache hits (josecelano-bot) 5e2059b chore(issues): archive closed issue #3019 spec to docs/issues/closed (josecelano-bot) Pull request description: Archives the spec for issue #3019 (closed by PR #3040) from `docs/issues/open/` to `docs/issues/closed/`, and records the post-merge evidence. - Verified issue #3019 is `CLOSED` on GitHub. - Updated frontmatter (`status: done`, `spec-path`, `related-pr: 3040`, `last-updated-utc`) and ticked the completed checkpoints and acceptance criteria. - V6 is partial: - The `coverage` run of the merge push passed with the GitHub Actions cache backend and no fallback warning. It had 0 hits because the cache service failed every write and many reads during that push; other jobs of the same push were degraded too. - No Dependabot branch push has run `docker-e2e` since the merge, so its sccache steps are not yet observed on the new action. It runs the same action as the `unit` job on the same image, verified in V4 and V5. - Two checkpoints stay unticked: no reviewer validated the acceptance criteria, and no independent reviewer received the spec. - The only remaining references to the old path are command lines recorded in the PR 3020 review audit, kept as history. - Pre-commit hooks passed. Refs #3019 🤖 Generated with [Claude Code](https://claude.com/claude-code) ACKs for top commit: josecelano: ACK 4ac24bb da2ce7: ACK 4ac24bb — the archive move, its frontmatter and reference audit, and the review audit record were recomputed at this head, with a clean merge against develop and no blocking finding. Tree-SHA512: 7614e8a86d36dd46fa7f40912a4306034721f626ebedb8b332eeaf5fe903c17b17d2b0b1f2220b3b3e40fabc5e95b930bc1adb5506eb09aadea931f4088339b6
Summary
Bare CI builds now keep building, without the compilation cache, when the
sccacheserver does not start. Before this change, a slow GitHub Actions cache service made the server miss sccache's 10-second startup timeout, and the firstcargocommand failed the job withsccache: error: Timed out waiting for server startup(four jobs on 2026-11-23).Changes
.github/actions/enable-sccache, run aftermozilla-actions/sccache-action:sccache --start-serverwithSCCACHE_GHA_ENABLED=trueandSCCACHE_IDLE_TIMEOUT=0, because the server selects its cache backend when it starts;RUSTC_WRAPPER=sccache,SCCACHE_GHA_ENABLED=trueandSCCACHE_IDLE_TIMEOUT=0(the server then lives for the whole job, so no later compile starts one without this check);sccache disabledwarning annotation;CARGO_INCREMENTAL=0in both cases. It usesshell: bash, so it also runs on thewindows-latestjobs.Enable sccachesteps intesting.yaml,os-compatibility.yaml,db-compatibility.yaml,coverage.yamlanddb-benchmarking.yamluse the action. Thedocker-e2eif:condition is kept.db-compatibility.yamlanddb-benchmarking.yamlalso list.github/actions/enable-sccache/**in their path filters, so a change to the action runs them.SCCACHE_IGNORE_SERVER_IO_ERROR(it does not cover the startup path in sccache v0.20.0) and retries were not used.Verification
linter alland the pre-commit gate pass. The timeout and the fallback were reproduced locally with a real sccache (V1, V2).server_startup_timeout_ms = 1:Unit (nightly)failed withTimed out waiting for server startupon the current workflow.Unitjobs passed and showed thesccache disabledwarning.josecelano-botfork starts no workflow runs, so the maintainer chose the draft PRs instead of fork branches.coverage.yamlruns on the merge push todevelop, anddocker-e2eruns its sccache steps only for a Dependabot branch push.Closes #3019
🤖 Generated with Claude Code
Summary by CodeRabbit