feat(review): bind acceptance to a verified checkpoint sha - #100
Merged
Conversation
An ACCEPT verdict now binds to the exact commit the reviewer saw. Any commit landing between the review brief and the verdict invalidates acceptance and ends the run as head-drift instead of accepted. Accepted runs with a PR then pass a final verification gate before the draft is lifted: local head equals the accepted checkpoint, the worktree holds no uncommitted task changes, the remote PR head matches, and required checks are green for that same sha. Only then does the PR become ready for human review.
Deploying with
|
| Status | Name | Latest Commit | Updated (UTC) |
|---|---|---|---|
View logs |
devloop | fbce89f | Aug 17 2026, 07:34 AM |
The fake gh now answers headRefOid, statusCheckRollup, and pr ready, so the accept loop exercises final verification instead of stopping at the draft PR. Asserts an accepted run is marked ready and an unclear run is not.
shellcheck flagged SC2016 on the single-quoted $all binding. The same classification works by piping the array directly, so the query needs no variable and no suppression comment.
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.
Why
An
ACCEPTverdict was not tied to anything. Nothing recorded which commit the reviewer actually saw, so a commit landing between the review brief and the verdict silently inherited an approval it never earned. Draft PRs were also opened and then left draft forever, with no gate between "the reviewer said yes" and "a human should look at this".What
head-driftinstead ofaccepted.How
REVIEWED_HEADis captured immediately before the reviewer starts and compared againstHEADwhen the verdict comes back. Only a verdict that survives that comparison setsACCEPTED_HEAD.final_verificationthen checks four things against that same SHA: local head matches, the worktree holds no uncommitted task changes, the remote PR head matches, and required checks are green. Pending, failing, or absent-with-a-lookup-error checks are not green. Only when all four pass doesgh pr readyrun.Two result lines are added to the run summary:
AcceptedandReadiness.Proof
bash scripts/devloop_test.sh: passes, except a pre-existingnightshift digestfailure caused by the suite writing to a hardcoded/tmppath that this sandbox denies. That failure reproduces unchanged onmain.ghlookup failure.Scope
Stack
mainfeat/living-review-status