revert: stale PR-head supersession (#842)#844
Conversation
|
Codex review: needs real behavior proof before merge. Reviewed July 24, 2026, 11:59 PM ET / July 25, 2026, 03:59 UTC. ClawSweeper reviewWhat this changesThis draft reverses the exact-review queue’s pre-dispatch stale-PR-head supersession and related audit/test coverage while preserving the later dispatch-422 classification fix. Merge readiness⛔ Blocked until real behavior proof from a real setup is added - 13 items remain Keep this draft open as a contingency artifact, not a merge candidate. Its stated purpose is to remove a current-main safeguard against dispatching obsolete pull-request heads, and no production evidence or maintainer decision establishes that restoring the prior failure mode is safer. Priority: P2 Review scores
Verification
How this fits togetherThe exact-review queue accepts GitHub events and explicit review commands, checks whether a target remains valid, then dispatches bounded review work. The reverted safeguard compares a queued pull-request head with GitHub’s live head so obsolete work is superseded before it consumes a workflow lease or dispatch attempt. flowchart LR
A[GitHub event or review command] --> B[Exact-review queue]
B --> C[Read live pull-request state]
C --> D{Queued head matches live head?}
D -->|Yes| E[Reserve lease and dispatch review]
D -->|No| F[Supersede or refresh queued work]
F --> G[Durable audit and queue metrics]
E --> H[Review workflow result]
Decision needed
Why: The patch intentionally trades prevention of obsolete workflow dispatches for an unproven contingency; choosing that operational policy cannot be resolved from tests or the branch alone. Before merge
Findings
Agent review detailsSecurityNone. Review metrics
Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Keep the live-head safeguard on current main unless maintainers review concrete production evidence and approve a narrower corrective change that preserves stale-work suppression and auditability. Do we have a high-confidence way to reproduce the issue? Yes from source and the linked incident narrative: queue an open pull request with an obsolete source head, then observe that this rollback removes the pre-dispatch live-head comparison. A live production reproduction of a harmful effect is not provided. Is this the best way to solve the issue? No. Reverting the safeguard restores a documented stale-work failure mode without evidence that the current implementation causes a worse production problem; a narrow evidence-backed correction would be safer. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against df5ec544d6d6. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
Draft contingency — do not merge
This is a prepared, exact rollback of #842, retained only in case maintainers determine its live-head admission behavior is unsafe in production.
It is based on current
mainafter #843, so it preserves the later dispatch-422 classification fix. It must not be merged merely because it exists.What it reverts
/pullshead comparison for source-head-bound exact-review work.Known consequence
Reverting #842 deliberately restores the prior behavior in which an open PR with an obsolete queued head can dispatch and later fail its lease check. Codex branch review reported this as P2; it is intentionally rejected only because this PR is a rollback artifact. A maintainer must reassess that trade-off against concrete production evidence before merging.
Validation
node --test test/dashboard-worker.test.ts— 205 passing on the rebased draft.pnpm run build:dashboard— passed.git diff --check origin/main...HEAD— passed.codex review --uncommitted— clean: exact inverse of fix(exact-review): supersede stale PR heads before dispatch #842.codex review --base origin/main— reviewed the current rebased branch; its sole P2 is the intentionally restored stale-head behavior described above.No queue, target, comment, workflow, Actions, or gate mutation was used to prepare this draft. No changelog or workflow change is included.