Skip to content

evidence refresh: det-mutation in 3 shards, and a budget that counts each case's own size (Part of #8033) - #8040

Merged
squid-protocol merged 1 commit into
mainfrom
fix/detmut-budget-shards
Nov 7, 2026
Merged

squid-protocol merged 1 commit into
mainfrom
fix/detmut-budget-shards

Conversation

@squid-protocol

Copy link
Copy Markdown
Owner

Part of #8033. This is why Evidence Refresh PRs stopped merging.

Why

det-mutation hit its 120-minute limit on 5 of the 10 refreshes up to 2026-11-07, and on the last 3 real runs in a row. A cancelled job fails the refresh (Fail when a re-proof failed), so the bot PR never gets auto-merge (#8006).

Run 42399865364 shows the mechanism: 23 stale ledgers were renewed in 14 minutes, then carddemo-signon (COSGN00C) re-ran its 718 recorded survivors because its harness / oracle moved. That's ~100 min at ~8 s a mutant, and the job was killed at 120. The budget (--budget-min 90) was checked only before a case started, never counted the case's own size, and started its clock only after translating every stale case.

What changes

  • det_mutation.py refresh:
    • The budget counts from the start, translation included.
    • Before re-running a case's survivors and new mutants, it estimates (SECONDS_PER_MUTANT × count). A case that can't finish in the time left is left for the next run before it starts: exit 2, which the lane already treats as a warning.
    • --shard I/N takes one share of the stale cases. The split is largest-first by recorded survivors onto the least-loaded shard, deterministic, so every shard computes the same split.
  • evidence-refresh.yml:
    • det-mutation is a 3-shard matrix (fail-fast: false, 150 min each, budget 130). The existing test still holds: the budget stays at least 20 min under the timeout.
    • One artifact per shard (refresh-detmut-N); the refresh job downloads them with pattern + merge-multiple. Ledgers are one file per case, so shards never overlap.

Runner time stays about the same: the work is split, not repeated. The wall time of the job drops from 120+ to the largest shard's share.

Checked

  • tests/tools/test_det_mutation.py: 3 new tests (the shard split covers every case exactly once and is deterministic; a case too large for the budget is left before it starts and fits once it can; refresh runs only its shard). 60 passed.
  • test_evidence_refresh_detmut_lane.py updated for the per-shard artifacts and the matrix. All 39 workflow-reading test files: 1500 passed, 7 skipped.
  • tests/ruff_audit.py --ci and tests/mypy_audit.py --ci: no new findings.

Independent of #8037 (coverage receipts). Both edit evidence-refresh.yml in different jobs.

🤖 Generated with Claude Code

…each case's own size (Part of #8033)

det-mutation hit its 120 min limit on 5 of the 10 refreshes to 2026-11-07, and
a cancelled job fails the refresh, so its bot PR never got auto-merge (#8006).
Run 42399865364: 23 cases in 14 min, then COSGN00C re-ran its 718 recorded
survivors (~100 min) because its harness moved; the budget was checked only
before a case started and never counted the translation.

det_mutation.py refresh: the budget counts from the start; a case whose re-run
(survivors + new mutants at SECONDS_PER_MUTANT) cannot fit what is left is left
for the next run before it starts (exit 2, the lane's warning); --shard I/N
takes one share of the stale cases, balanced by recorded survivors.
evidence-refresh.yml: det-mutation is a 3-shard matrix (150 min, budget 130),
one artifact per shard, merged by the refresh job.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@github-actions

github-actions Bot commented Nov 7, 2026

Copy link
Copy Markdown
Contributor

🐦‍⬛ Muninn Security Scan

✅ No security issues found.

🐦‍⬛ Powered by Muninn · Skald Lab

@squid-protocol
squid-protocol merged commit 3c311cd into main Nov 7, 2026
40 checks passed
@squid-protocol
squid-protocol deleted the fix/detmut-budget-shards branch November 7, 2026 22:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant