Repository navigation
fix(review): publish exact merge readiness state - #1059
Conversation
|
Codex review: needs maintainer review before merge. Reviewed September 2, 2026, 5:09 PM ET / 21:09 UTC. ClawSweeper reviewWhat this changesThis PR adds an advisory exact-head readiness state to durable PR review comments and makes oversized-comment fallback publication a guarded-open, batch-continuing outcome. Regression provenancePossible regression — probable (reviewed change; failure trace). No predecessor PR is attributed. Merge readinessKeep open for maintainer review: the member-authored branch is unmerged, and its exact readiness and guarded-publication behavior remains a distinct change rather than a demonstrated main-branch replacement. Priority: P2 Review scores
Verification
How this fits togetherClawSweeper converts structured review reports into durable GitHub comments, whose markers guide review presentation and repair-loop eligibility. Its apply workflow publishes those comments and records the resulting mutation and open/closed disposition in the action ledger. flowchart LR
A[Structured review report] --> B[Readiness calculation]
B --> C[Durable review comment]
C --> D[GitHub publication receipt]
D --> E[Apply workflow]
E --> F[Action ledger]
B --> G[Repair-loop eligibility]
Before merge
Agent review detailsSecurityNone. Review metrics
Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Land the focused readiness and publication hardening only after the current-head automation checks complete, retaining the exact receipt and malformed-input regressions as the contract boundary. Do we have a high-confidence way to reproduce the issue? Yes—source and the supplied current-head compiled-CLI trace define a high-confidence scenario: an oversized review must publish a bounded blocked receipt, release its lease, and allow the next selected item to continue. Is this the best way to solve the issue? Yes—the shared readiness calculation plus an exact receipt-verified fallback is the narrowest maintainable fix because presentation and automation no longer independently infer readiness. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against ff071968ca4e. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (31 earlier review cycles; latest 8 shown)
|
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
Punchcard-Session: amber-timber-river-t1
Punchcard-Session: brisk-workshop-valley-n7
Punchcard-Session: brisk-workshop-valley-n7
Punchcard-Session: brisk-workshop-valley-n7
Punchcard-Session: brisk-workshop-valley-n7
Punchcard-Session: brisk-workshop-valley-n7
Punchcard-Session: brisk-workshop-valley-n7
Punchcard-Session: brisk-workshop-valley-n7
Punchcard-Session: brisk-workshop-valley-n7
Use the existing structured next-step, findings, and proof policy for public readiness. Remove the proposed sentence classifier, generated prose fixture, and generic competing-comment cleanup. Require exact trusted publication receipts. Record a bounded fallback as verified guarded-open work, retain its receipt in event output, release the owned lease, and continue the batch. Preserve valid issue recovery without PR-only state and compare review timestamps by instant during re-sync. Validated with the compiled apply CLI against a controlled GitHub transport, a paired oversized baseline, processed-limit and owned-cleanup controls, and pnpm run check on Node 24. Co-authored-by: Vincent Koc <[email protected]>
|
🦞👀 Pull request received. I will update this pull request when review starts. |
|
Maintainer disposition for The current-head CI gate, CodeQL, and production automerge E2E are green. The isolated Node 24 gate passed 4,494 tests with seven skips plus the separate 13-test coverage gate; the paired native proof reproduced the old batch abort and verified fallback receipt, continuation, processed-limit handling, and owned cleanup. Managed Codex P0 reviews of both the final staged tree and committed branch found no actionable findings. Landing this rewrite with Vincent Koc’s original contribution and credit preserved. Native evidence and its controlled-service limitations are recorded in the PR body. |
… PRs The first revision published a fourth review-state value, `awaiting-maintainer`. Released v0.3.3 readers accept only `ready`, `blocked`, and `needs-changes` and return null for anything else, so the causal selector would drop the new comment and could prefer an older one. The retained contract from openclaw#1059 requires coordinated versioning for an incompatible change; this is not one. `awaiting-maintainer` is now a presentation state only. The marker keeps the `blocked` wire value and adds `hold=maintainer_decision`, an attribute v1 readers ignore and newer readers can use to tell the owner wait from other blocks. The identity reader is back to the three-state contract and fails closed on unknown states. The verdict line, readiness block, empty Before merge checklist, status label, and `hold=maintainer_decision findings=0` verdict are unchanged; the persisted comment format does not change. Co-Authored-By: Claude Fable 5.1 <[email protected]>
… PRs The first revision published a fourth review-state value, `awaiting-maintainer`. Released v0.3.3 readers accept only `ready`, `blocked`, and `needs-changes` and return null for anything else, so the causal selector would drop the new comment and could prefer an older one. The retained contract from #1059 requires coordinated versioning for an incompatible change; this is not one. `awaiting-maintainer` is now a presentation state only. The marker keeps the `blocked` wire value and adds `hold=maintainer_decision`, an attribute v1 readers ignore and newer readers can use to tell the owner wait from other blocks. The identity reader is back to the three-state contract and fails closed on unknown states. The verdict line, readiness block, empty Before merge checklist, status label, and `hold=maintainer_decision findings=0` verdict are unchanged; the persisted comment format does not change. Co-Authored-By: Claude Fable 5.1 <[email protected]>
Related: openclaw/openclaw#120232
What Problem This Solves
Resolves contradictory review guidance: a PR could display required work while its automation markers reported readiness. Oversized reviews could abort the apply batch, including after successfully publishing a blocked fallback.
Why This Change Was Made
One readiness owner now supplies the visible checklist, versioned state, and repair-loop pass eligibility from structured
next_step, typed findings, and existing proof/security policy. Historical reports retain their defined legacy interpretation. The rewrite removes the proposed English sentence classifier, fixture generator, full-comment golden snapshots, and generic competing-comment sweep.Publication accepts only a trusted author, positive safe server ID, and exact submitted body; PATCH also requires the targeted ID. An unusable returned acknowledgement can recover through fresh scoped readback. A verified oversized fallback records its actual receipt as guarded-open, carries the mutation receipt through event output, releases the owned lease, respects the processed limit, and continues the batch. Re-sync compares timestamp instants so canonical ISO spelling cannot add the same review to history twice. It never claims a completed review or grants repair/close permission.
Identity-less fallbacks establish a server-ID barrier that only a complete review from a newer owned lease can clear. PR successors require matching exact-head v1 state and durable identity; issues use
sha=naplus a valid source revision without a PR-only state marker. Older leases cannot regain authority through later client timestamps. Publication preserves contributor and other workers’ comments; existing explicitly guarded lease-acquisition cleanup remains separate.User Impact
Maintainers receive consistent visible and machine-readable guidance, and one oversized review no longer prevents later selected items from being processed. This continues Vincent Koc’s original contribution with a simpler implementation.
Owner decisions retained: the additive v1
ready|blocked|needs-changesmarker is supported only with matching item/head, valid review time, and owned positive lease identity. Unknown states/versions or incomplete identity fail closed. Additive metadata is permitted; incompatible changes require a new version, coordinated consumer support, and documented deprecation. The marker remains advisory. Lease-owned recovery is accepted; publication gains no general deletion authority.OpenClaw Bay Impact
The existing review-publication path carries the verified guarded-open result through event proof and the action ledger. Bay’s observer contract and UI are unchanged. The proof below does not claim deployed Bay convergence.
Documentation Impact
Updated active
docs/pr-review-comments.md: structured readiness, exact receipts, the 60 KiB fallback, batch continuation, causal identity, and owned cleanup. Durable review publication owns this contract; production state/publication code and the compact v1 fixture are its sources of truth. Reviewed at the frozen tree below; marker, receipt, or lifecycle changes must update it.Evidence
d6e850d28eedd1b35585fb110965b2fa24efe5b7; tree:8d3a69231aebdaa1b4963ec771a031509eb709f7.pnpm run checkpassed on Node 24.18.1 / pnpm 11.10.0: 4,494 tests passed, seven skipped, zero failures/cancellations; the separate 13-test coverage gate also passed. This includes builds, formatting, lint, docs/static checks, and coverage gates.Real Behavior Proof
AWS Crabbox lease
cbx_768de70d3fd1, runrun_38b07d0b0821, executed the actual compiled apply CLI through its existing GitHub command seam against a stateful loopback service. Dependencies were installed from the frozen lockfile. The tested staged tree is byte-identical to the final commit tree above; source, runtime assets, and complete compiled-bundle digests were checked before and after execution.Pinned baseline
2bd06139e0d0d404250d474a43e8f2adfa899f70attempted a 196,209-byte comment, received the fixture's size rejection, exited unsuccessfully, and never published the second item. The candidate published a 689-byte blocked notice, recorded its real ID/URL/body digest, released its owned lease, and published the second item. The processed-limit-one control stopped after the blocked item and still released its lease. Across both candidate cases: three durable writes, three owned-lease deletions, unchanged contributor/status sentinels, no close/merge/dispatch, and zero unexpected transport operations. Both loops exited successfully and closed their servers.The actual exported apply result reached the compiled event consumer as guarded-open with its mutation receipt; it never claimed a completed full review. Strict receipt rejection, separate causal recovery negatives, and ledger classification are focused test evidence, not additional native scenarios.
Artifact SHA-256:
1c7228483698c58c2e765088a6abf821ec301454162ef3c9b62f2e9720e1e607. Candidate proof JSON:52839adbb86c8b89206bcd0670d211a4faa11fe5336013a118213275b05125d0. Proof script:9baceae2240744ccdfbdad6ea4a57abaafe9d0f475bd51148300de28bfe4eba2. Evidence retains both baseline and candidate CLI logs, request traces, stored comments, reports, and validation outputs. The credential-free lease is retained temporarily for the separate lifecycle-inventory follow-up.This proves compiled behavior against a controlled service; it does not establish live GitHub permissions/eventual consistency, GitHub's size-limit implementation, downstream Clownfish integration, model inference, or deployed Bay convergence.