Repository navigation
fix(pr-pipeline): re-run merge-risk runs the lanes kill switch stopped - #17315
Conversation
…pped reviews on the first pass after the reset The lost-run reconciler never listed pr-rate-merge-risk runs, so a rating the GITHUB_TOKEN floor stopped stayed unrated. The rater's trigger check already takes the reconciler's record, so it joins RECORDED_LANES with its own judge and write steps (Rate the pull request, Write the rating). A floor-failed pr-require-checks run took one pass and the head's kill-switch-stopped reviews another, since the floored ci-status never got to name them; with one review lane per pass, ci-status could reach attempt 4, past RECONCILER_ATTEMPT_CAP. A floor or lanes-switch set now carries the head's stopped reviews, read from their own jobs, and both lanes go in one pass. Every floor kind now waits until a minute past the pool reset its refusals name (floorReset, a guessed time only when none is real), so its one re-run is not spent inside the floor; a waiting run keeps the pass from writing clean. The workflow file's copy of the Review paragraph, which said one lane per pass, is dropped: reconcile.mjs's header is the description. New rationale lives here rather than in new comments, under the comment lint. Co-Authored-By: Claude Opus 5.5 <[email protected]>
A floor set carrying both stopped reviews holds three records. Placed after another PR's floor set, it found two uploads left and was deferred whole, so the 21:50 pass would have re-run less than it did before. When the whole set does not fit and the set without its reviews does, the floor re-run goes now and the reviews wait for the next pass; ci-status then reaches attempt 3 at most, inside RECONCILER_ATTEMPT_CAP. Co-Authored-By: Claude Opus 5.5 <[email protected]>
A rater run the lanes kill switch stopped succeeds with no rating (its report-only stop), so the lost-run listing never sees it and the PR stays "Merge-Risk: unrated". The rater joins FAULT_HELD_LANES: its succeeded first attempts are listed and read like a held pr-verify run, inside the same FAULT_HELD_READS cap and followsNoOpenHead filter, and one whose every leg that ran shows the kill-switch step run and the resolver skipped is re-run once, whole, recorded. Any other succeeded rater run is settled, so its jobs are read once. The reconciler reads nothing while the switch is on, so the re-run comes on the first pass after it lifts; attempt 2 is never taken again. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Resolved reconcile.test.mjs: kept this branch's RATER_RESOLVE_STEP and RATER_SWITCH_STEP imports, its third held-run listing (pr-rate-merge-risk) in the read count, and its switch-stopped rater tests. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Lane run report
Failed GitHub API calls
|
Lane run report
Failed GitHub API calls
|
|
claude-security-review needs no new review of Security review: PR #17315I found no security issues. I read every hunk of all 3 changed files. This lane already reviewed an earlier head, so this review was blocking only: it would report only CRITICAL and IMPORTANT findings, and none came up. What changed since the last review. The reconciler used to require that every leg showed the switch stopped it. It now decides on the last leg that ran, taking the legs in key → subscription → fallback order ( Trust-boundary checks
Settled thread. The between-legs window thread is resolved, and its fix is the change described above. I am not raising it again. Spend. Each stopped rater run is re-run once after the switch lifts. That spends prepaid model credit for one rating, plus a few extra GitHub API reads per pass. Neither can start a real charge. critical-findings: 0 |
|
claude-review needs no new review of Code review: re-run merge-risk runs the lanes kill switch stoppedNo blocking findings at The PR adds
Earlier finding is fixed. My earlier comment was about a switch turned on between legs leaving a run unrated and then settled. That thread is resolved, and the fix is in the head code (reconcile.mjs#L1107-L1120):
A new test covers the handoff case, and the workflow pin test now asserts that the three job names equal What I checked in the code:
I did not run the tests myself. The author's results (263 pass, the mutants, Spend: no Other checks:
Loosened-check verdict: fail. This is the default, because the prompt had no Verifier dropped 0 of 0 candidates. |
A switch set between legs stopped the subscription or fallback leg after the key leg's resolver had run and handed off, so the every-leg test read the run as rated and settled it unrated. The run now counts as stopped when the last leg that ran (key, subscription, fallback order) shows the switch step passed and the resolver skipped; an earlier leg hands off only when it did not rate. A test pins the leg names to the workflow's jobs. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Refs: #17313
Summary
Follow-up to #17313, based on its branch. A merge-risk run the lanes kill switch stopped now gets re-run once, on the reconciler's first pass after the switch lifts. Before this, the run ended green with no rating (
pr-rate-merge-risk.yml:110-111), and its PR stayedMerge-Risk: unrated.Fix
pr-rate-merge-risk.ymljoinsFAULT_HELD_LANES. Its succeeded first attempts are listed and read the same way a held pr-verify run is:FAULT_HELD_HOURSback, or from the carriedheld_since;FAULT_HELD_READSper pass.Check the kill switchrun andResolve the pull requestskipped. The rater'scheck-kill-switchcall passes nobudget, so only the switch skips the resolver. A stopped run is re-run whole, recorded asreconcile-rerun-<id>-2-<main tip>, at attempt 1 only.main'sKILL_SWITCHstop), so the re-run comes on the first pass after the switch lifts.MAX_IN_FLIGHTand the record-upload cap are unchanged.Cost: up to three more read calls per pass (one held-run listing, plus job reads for new succeeded rater runs, each read once and then carried as settled).
Verification
node --test .github/scripts/maintenance-reconcile-lost-runs/*.test.mjs: 263 pass, 0 fail.fixtures/runs-switch-stopped-rater-2026-11-18.json):scripts/check-affected.sh: 13 passed, 6 skipped.Related
🤖 Generated with Claude Code