Skip to content

fix(review): align required proof comments and status labels - #1310

Merged
steipete merged 1 commit into
mainfrom
steipete/gifted-solomon-86d104
Aug 30, 2026
Merged

steipete merged 1 commit into
mainfrom
steipete/gifted-solomon-86d104

Conversation

@steipete

Copy link
Copy Markdown
Contributor

What Problem This Solves

Resolves contradictory PR review guidance when the reviewer records real-behavior proof as not_applicable but the host's existing proof policy still requires it. A real README-only local-range review said proof was needed before merge, displayed Real behavior: Not applicable, and added an Add real behavior proof — Not applicable checkbox. The same split could select an automerge armed status while the machine verdict correctly remained needs-human.

Why This Change Was Made

One read-only host proof-policy projection now supplies merge blocking, readiness, verification, checklist guidance, and public/apply-time status selection. It retains the recorded reviewer assessment separately rather than rewriting valid N/A data or trusting it as an exemption.

The existing docs/-only exemption remains narrow: root README.md is not newly exempt. Trusted-author, override, authority-chain, and machine merge/repair/close decisions are preserved. Historical verification failures remain separate maintainer-owned blockers; failed reviews stay unassessed instead of acquiring positive readiness labels.

User Impact

Required proof has a consistent status and an actionable reason across the comment and labels. Recorded N/A context and ratings remain visible as the reviewer's assessment, not as permission to bypass host policy. No merge-policy broadening or historical comment rewrite is included.

OpenClaw Bay Impact

No Bay code or schema change is needed. Its observer projection does not consume this proof assessment or checklist.

Documentation Impact

Updated the active docs/pr-review-comments.md guidance to distinguish the recorded assessment from the host requirement, including receipt ownership, and added the user-facing changelog entry. Reviewed AGENTS.md, CONTRIBUTING.md, the documentation index, and the owning review/policy guidance. No prompt or schema policy was broadened.

Evidence

  • The original regression failed before the fix in five assertions spanning native comment rendering and report-based status selection for both root README and arbitrary source-file N/A reports.
  • An independent Codex review caught a failed-review status regression in the first implementation. Four additional regressions failed before its correction and pass afterward. The current precommit Codex review is clean through P2.
  • Final focused proof: 94 passed, 0 failed. The prior full local repository check passed 4,071 tests with 9 skips and 0 failures; hosted CI validates the committed PR head.
  • 3,456 combinations match the original merge gate exactly, including historical receipts, failed reviews, overrides, applicability and contributor-action flags. 600 report-level controls retain identical gate headlines and machine markers.

Real Behavior Proof

Claim and exercised surface: the built production report parser/policy/comment renderer now projects a required proof assessment consistently without changing the underlying proof gate or recorded N/A facts.

Scenario: replay the complete sanitized report from an actual native local-range Codex/TruffleHog review of a synthetic README-only PR. Its facts are author_association: CONTRIBUTOR, pull_files: ["README.md"], and proof {status: "not_applicable", evidenceKind: "not_applicable", needsContributorAction: false}. These are real prior reviewer results, not a newly fabricated model response.

Current source: fc057e80383a1721f4fa9b2b37e2217d02b8a5f0, based on 74b0f8552fde46842a933ca360ed272f0212193e. Environment: macOS, Node 24.20.0, repository-pinned pnpm 11.10.0. CLAWSWEEPER_TARGET_REPO=openclaw/clawsweeper is set before importing dist/clawsweeper.js.

Executed native replay:

CLAWSWEEPER_TARGET_REPO=openclaw/clawsweeper node .artifacts/host-proof-projection-20260830/render-proof.mjs after pr-head

Observed: the headline and machine verdict continue to block proof; verification now says Required by policy, readiness is blocked, and the checklist explains why recorded N/A does not satisfy the current policy. The original report bytes, proof fields, repository links, and provenance roles remain unchanged.

{
  "repositoryContext": "openclaw/clawsweeper",
  "contextSetBeforeImport": true,
  "proofGateStillBlocks": true,
  "verdictStillNeedsHuman": true,
  "originalArtifactUnchanged": true,
  "allAssertionsPassed": true
}

Input report SHA-256: da92b5a662db5bfc4ca3b887a939b227c4880a2bc735b6c864e6b09edd186010.
Final native Markdown SHA-256: 4e5d2c2e5c47da08a9adb599f7b949821215cc6e65a615551599fce67745d624.

The captures below show that actual native Markdown output, rendered locally with synthetic-only content. They are not screenshots of a historical GitHub comment being edited.

Limits: this is deterministic host-render proof using an existing real review artifact, not a fresh provider review. The disposable browser only presents local Markdown and makes no external page requests. The proof does not exercise GitHub publication or authorize a policy exemption. Tests, gate parity, CI, and current PR review support the native-render claim rather than substitute for it.

Before: contradictory required-proof and Not applicable guidance

After: required-proof status and reason agree while recorded N/A is retained

Use the shared host proof projection for review comments and status labels while preserving recorded reviewer assessments and the existing proof merge gate.
@clawsweeper

clawsweeper Bot commented Aug 30, 2026

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

@clawsweeper clawsweeper Bot added merge-risk: 🚨 automation 🚨 Merging this PR could break CI, automerge, proof capture, label sync, or automation. P2 Normal priority bug or improvement with limited blast radius. proof: sufficient Contributor real behavior proof is sufficient. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Aug 30, 2026
@clawsweeper

clawsweeper Bot commented Aug 30, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed August 30, 2026, 3:30 PM ET / 19:30 UTC.

ClawSweeper review

What this changes

The PR centralizes required-proof policy evaluation and applies it consistently to merge readiness, review comments, automation markers, and PR status labels.

Merge readiness

⚠️ Ready for maintainer review - 1 item remains

Keep this PR open for normal maintainer review. The introduced shared policy consistently distinguishes a recorded not-applicable assessment from a host-required proof gate, and the supplied native replay directly exercises the rendered output.

Priority: P2
Reviewed head: fc057e80383a1721f4fa9b2b37e2217d02b8a5f0

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) The PR has direct production-path replay evidence and comprehensive boundary coverage for a contained automation correction.
Proof confidence 🦞 diamond lobster (5/6) Sufficient (terminal): The PR body provides an exact-head terminal replay of the built production report parser, proof-policy projection, and comment renderer against a sanitized artifact from a real local-range review; the recorded after-fix result keeps the gate blocked and verdict needs-human while aligning visible guidance. The supplied screenshots were not locally available, but the terminal trace directly covers the changed runtime path.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Verified Sufficient (terminal): The PR body provides an exact-head terminal replay of the built production report parser, proof-policy projection, and comment renderer against a sanitized artifact from a real local-range review; the recorded after-fix result keeps the gate blocked and verdict needs-human while aligning visible guidance. The supplied screenshots were not locally available, but the terminal trace directly covers the changed runtime path.
Evidence reviewed 5 items Canonical proof policy: The added policy preserves the recorded assessment while separately deriving whether proof, verification, or contributor action blocks merge; a not-applicable assessment on an applicable external PR remains proof-blocking.
Consistent label routing: Status selection now consumes the shared policy for unresolved contributor work and readiness, preventing an automerge or ready label when the policy still blocks merge.
Regression coverage: Focused tests cover external N/A reports for root README and source paths, docs-only and trusted-author exceptions, overrides, failed reviews, malformed receipts, rendered comments, and apply-time label synchronization.
Findings None None.
Security None None.

How this fits together

ClawSweeper turns stored Codex review reports into public PR comments, labels, and merge/apply decisions. The new policy layer consumes recorded proof and verification state, then feeds those presentation and workflow outputs.

flowchart LR
A[Stored review report] --> B[Proof policy projection]
B --> C[Merge readiness]
B --> D[Public review comment]
B --> E[PR status labels]
B --> F[Automation markers]
C --> G[Apply and merge gates]
Loading

Before merge

  • Resolve merge risk (P1) - This changes review-label and automation-marker routing; an uncovered policy boundary could misstate contributor follow-up or merge readiness.
Agent review details

Security

None.

Review metrics

Metric Value Why it matters
Changed surface 16 files affected The change spans the shared policy, all main presentation consumers, documentation, and targeted regression tests.
Production versus test delta production +213/-156, tests +740/-22, docs +18 Most added lines are boundary and regression coverage for a smaller policy refactor.

Merge-risk options

Maintainer options:

  1. Accept the scoped automation change (recommended)
    The shared projection retains the existing merge gate and the focused coverage exercises the report, comment, marker, and label boundaries affected by this change.

Technical review

Best possible solution:

Retain one canonical proof-policy projection, preserving recorded reviewer facts while testing contributor, docs-only, override, failed-review, and verification-receipt boundaries at every output surface.

Do we have a high-confidence way to reproduce the issue?

Yes, at high confidence: the PR body supplies an exact-head native replay of the production parser/policy/renderer using a sanitized real review artifact, and the source defines the asserted proof-policy path.

Is this the best way to solve the issue?

Yes. A single shared policy projection removes duplicated interpretations without rewriting valid reviewer assessments or widening the existing proof exemption.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 74b0f8552fde.

Labels

Label changes:

  • add P2: A wrong review-policy projection can misroute contributor-facing status and merge readiness, but the effect is limited to ClawSweeper automation.
  • add merge-risk: 🚨 automation: The PR intentionally changes review comment, label, and marker automation that governs follow-up and readiness.
  • add proof: sufficient: Contributor real behavior proof is sufficient. The PR body provides an exact-head terminal replay of the built production report parser, proof-policy projection, and comment renderer against a sanitized artifact from a real local-range review; the recorded after-fix result keeps the gate blocked and verdict needs-human while aligning visible guidance. The supplied screenshots were not locally available, but the terminal trace directly covers the changed runtime path.
  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🦞 diamond lobster and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (terminal): The PR body provides an exact-head terminal replay of the built production report parser, proof-policy projection, and comment renderer against a sanitized artifact from a real local-range review; the recorded after-fix result keeps the gate blocked and verdict needs-human while aligning visible guidance. The supplied screenshots were not locally available, but the terminal trace directly covers the changed runtime path.

Label justifications:

  • P2: A wrong review-policy projection can misroute contributor-facing status and merge readiness, but the effect is limited to ClawSweeper automation.
  • merge-risk: 🚨 automation: The PR intentionally changes review comment, label, and marker automation that governs follow-up and readiness.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🦞 diamond lobster and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (terminal): The PR body provides an exact-head terminal replay of the built production report parser, proof-policy projection, and comment renderer against a sanitized artifact from a real local-range review; the recorded after-fix result keeps the gate blocked and verdict needs-human while aligning visible guidance. The supplied screenshots were not locally available, but the terminal trace directly covers the changed runtime path.
  • proof: sufficient: Contributor real behavior proof is sufficient. The PR body provides an exact-head terminal replay of the built production report parser, proof-policy projection, and comment renderer against a sanitized artifact from a real local-range review; the recorded after-fix result keeps the gate blocked and verdict needs-human while aligning visible guidance. The supplied screenshots were not locally available, but the terminal trace directly covers the changed runtime path.

Evidence

What I checked:

  • Canonical proof policy: The added policy preserves the recorded assessment while separately deriving whether proof, verification, or contributor action blocks merge; a not-applicable assessment on an applicable external PR remains proof-blocking. (src/clawsweeper-proof-policy.ts:35, fc057e80383a)
  • Consistent label routing: Status selection now consumes the shared policy for unresolved contributor work and readiness, preventing an automerge or ready label when the policy still blocks merge. (src/clawsweeper-label-policy.ts:145, fc057e80383a)
  • Regression coverage: Focused tests cover external N/A reports for root README and source paths, docs-only and trusted-author exceptions, overrides, failed reviews, malformed receipts, rendered comments, and apply-time label synchronization. (test/pr-proof-automation.test.ts:104, fc057e80383a)
  • Real behavior evidence: The PR body records an after-fix native replay against the exact head, using a sanitized real review artifact; its reported output confirms the proof gate and needs-human verdict remain while the rendered verification and checklist wording agree. (fc057e80383a)
  • Feature history routing: Recent history shows earlier review-gate work in this area, including the historical smoke proof-credit fix. (src/clawsweeper-label-policy.ts, 468dab46ff57)

Likely related people:

  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)
  • Vincent Koc: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

@steipete

Copy link
Copy Markdown
Contributor Author

Maintainer disposition for fc057e80383a1721f4fa9b2b37e2217d02b8a5f0: accept the review's recommended scoped automation change.

The remaining checklist item describes general automation-routing risk, not a concrete defect. The current ClawSweeper review reports no actionable findings or security concerns, sufficient terminal proof, and readiness for maintainer look. Acceptance is supported by the exact-head native replay, 94 passing focused tests, unchanged results across 3,456 policy-input combinations and 600 report-level gate/marker controls, and clean precommit and committed-branch Codex reviews through P2.

This accepts ordinary maintenance risk; it does not grant a proof override or broaden merge policy. Recorded N/A facts, the narrow docs/ exemption, trusted-author rules, and machine gate decisions remain unchanged. The reviewed PR head and body are unchanged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merge-risk: 🚨 automation 🚨 Merging this PR could break CI, automerge, proof capture, label sync, or automation. P2 Normal priority bug or improvement with limited blast radius. proof: sufficient Contributor real behavior proof is sufficient. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant