Repository navigation
ci(#6675): no cache is saved by a pull request; graph-accuracy seeds its caches nightly - #6676
Merged
Merged
Conversation
…its caches nightly on main The Actions cache was 10.69 GB / 127 entries (limit 10 GB), the oldest last read 10.6 h earlier, so main's caches were evicted within about half a day. 20 combined actions/cache steps in 7 pull_request workflows saved under the PR's own ref, which nothing else reads: 2.18 GB of scip-java (graph-accuracy never ran on main), 9 PR copies of db2-odbc-cli, and go / cargo / m2 / image copies. Each is now actions/cache/restore plus a main-only save at the end of its job (only on a miss, continue-on-error, as #5024); setup-go's cache is off on a PR; graph-accuracy-audit.yml gets a nightly + dispatch run (every gate) that seeds its caches on main, and Main Watch watches it. test_cache_keys.py fails on any combined cache step in a PR workflow and on a save a PR can reach. smoke-test / ground-truth pip keys are untouched (owner-protected, #4935). Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Contributor
Contributor
|
No description provided. |
Contributor
|
No description provided. |
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Closes #6675.
Problem
The Actions cache is over GitHub's 10 GB limit: 10.69 GB in 127 entries on 2026-10-25, the oldest last read 10.6 h earlier. Past the limit GitHub evicts the least recently used entries, so caches saved on main survive about half a day.
cache-prune.ymltrims to ~6 GB nightly (the 2026-10-25 run planned 49 deletes, 10.20 -> 5.96 GB), and PRs refill it past the limit within ~12 h.The leak is combined
actions/cachesteps inpull_requestworkflows. A PR's save is scoped to its own ref, which no other PR can read. #4968 (java-compile) and #5024 (corpora) already fixed this for their caches; 20 steps in 7 workflows were left:Change
actions/cache/restore(sameid, so existingsteps.<id>.outputs.cache-hitchecks keep working) plus anactions/cache/saveat the end of its job. The save runs only whensuccess() && github.event_name != 'pull_request' && cache-hit != 'true', keeps the step's originalif, and iscontinue-on-error, the same shape as Siblings of #4968: per-PR cache saves (mainframe-corpora key) #5024. A partialrestore-keyshit still saves on main, as the combined step's post-save did.cache: ${{ github.event_name != 'pull_request' }}, since its built-in cache restores and saves in one step (26 MB of modules on a PR).schedule(nightly, every gate) andworkflow_dispatch. This seeds the one shared scip-java / cargo / Go copy on main, and gives the graph gates a main-side signal. Main Watch now watches it.test_cache_keys.py: fails on any combined cache step in a PR workflow, and on any save a PR can reach (!= 'pull_request', or an==pinning schedule / dispatch / push, as det-sweep's durations saves do).Not changed: the pip keys of
smoke-test.yml/mainframe-ground-truth.yml(owner-protected, #4935).Expected effect
Steady state frees ~2.6 GB of PR-scoped copies (scip-java alone 2.18 GB, collapsing to one main copy of ~0.3 GB), and stops the per-PR re-saves that drive the eviction churn. A PR on graph-accuracy restores scip-java from main instead of starting cold. Measure after merge:
gh api repos/squid-protocol/gitgalaxy/actions/cache/usageand the oldest entry's age a day later; that age should go well past 10.6 h.Verification
Conflicts to expect
equivalence-e2e.ymland appends a step at the end of the shard job, and both PRs add a line tomain-watch.yml. Whichever merges second needs a rebase: keep both appended steps, and add the save steps for any cache step the other side added.🤖 Generated with Claude Code