Skip to content

fix(review): stop showing non-actions as remaining merge work - #1348

Merged
steipete merged 1 commit into
mainfrom
steipete/cool-lewin-283c0f
Sep 2, 2026
Merged

steipete merged 1 commit into
mainfrom
steipete/cool-lewin-283c0f

Conversation

@steipete

@steipete steipete commented Sep 2, 2026

Copy link
Copy Markdown
Contributor

What Problem This Solves

Fixes an issue where maintainers see a remaining-work checkbox on an otherwise clean ClawSweeper review when its routing explanation says “No concrete repair remains after this review.” The trigger was the review on PR1341: the visible review reported no actionable defect but displayed one remaining item.

Why This Change Was Made

The renderer was treating routing prose as action intent. This change records a producer-owned nextStep assessment, validates and persists it in the canonical report, and consumes it only for the derived Before merge next-step item. workCandidate: none remains an automation-routing state, not permission to hide human-owned blockers.

Explicit non-action removes that item; explicit required actions survive negation, contrast, and missing trigger keywords. Findings, security, proof, merge risks, decisions, and rating remediation remain independent. Contributor-changelog normalization preserves mixed or ambiguous required actions. No phrase denylist is added to the general action detector.

User Impact

New reviews with explicit non-action no longer show the bogus checkbox or inflate the remaining-item count. Genuine required actions stay visible. Issues retain their existing next-action guidance. Scores and repair/automerge markers are unchanged.

Historical reports are not migrated: absent, malformed, or ambiguous intent keeps the conservative legacy fallback. The original review’s raw structured record was not recovered; this is not a claim that it already contained the new field, and this PR does not rewrite that old comment.

OpenClaw Bay Impact

None. The observer projection does not consume this checklist. No observer routes, controls, workflow mutations, or live repair/merge eligibility change.

Documentation Impact

Updated the active implementation contract in docs/pr-review-comments.md. Added the historical, reproducible recipe docs/proof/review-next-step-intent/README.md with its owner, pinned baseline, source references, commands, and explicit proof limits. No changelog edit is included.

Evidence

  • Candidate head: 57de5d52eed4202200b28e10da0a76e21bff5ea8.
  • pnpm run build:node and 200 focused parser, renderer/count, risk, labels, prompt-policy, history, and no-op tests passed.
  • Codex pre-commit autoreview completed with no accepted findings at its configured P0 threshold.
  • An earlier Mac full-check attempt had five unchanged action-ledger timing/fairness failures, all five of which passed in an isolated rerun; the broad run was stopped after approximately 46 minutes. That run is not claimed as a full-check pass. Current-head repository CI must pass before landing.

Real Behavior Proof

Claim and exercised surface: an explicit recorded non-action must not manufacture a PR checkbox/count, while required actions and independent blockers remain visible. The replay calls the compiled production renderers with identical serialized report bytes, then separately runs the real decision parser, report writer, intent reader, and renderer.

Environment and command: Node 24+, pinned pnpm dependencies, local Node execution; no container image or lease is claimed for this replay. Baseline source is 39592f04448bdc34d37b9e7f8d5c5d7c828b73f2, built from git archive with the same installed compiler. Candidate is the commit above. Follow the checked-in README to build the baseline, then run:

node docs/proof/review-next-step-intent/replay.mjs --baseline-dist "$BASELINE_DIR/dist" --baseline-sha 39592f04448bdc34d37b9e7f8d5c5d7c828b73f2

Observed result: all ten paired cases and the producer/report round-trip passed on the candidate head. The reported sentence produced one checkbox/count on the baseline and zero on the candidate. All three 5/6 score rows and the automation markers matched in every paired case. Controls retain required contrast/negation, keyword-free human action, independent findings/security, and conservative legacy/malformed behavior. The local receipt records exact source/build/fixture hashes and Git state.

Before / after: these images show the actual replay’s rendered Markdown in an isolated browser. Both are inspected, synthetic-only local fixtures, not screenshots of a live GitHub comment.

Before: inferred action After: explicit non-action
Synthetic baseline review with a false next-step checkbox Synthetic candidate review with no remaining next-step item

Limits: no live model review, publication, queue, apply, repair, or merge path is exercised by the local replay. The historical raw record is unavailable. Other independent blockers have focused regression coverage rather than exhaustive replay. No unrelated PR or OpenClaw product branch is modified.

Record canonical next-step intent separately from automation routing. Explicit none omits only the derived next-step checkbox and count; required human actions and independent blockers remain visible regardless of workCandidate.

Preserve conservative fallback for absent, malformed, or ambiguous legacy report intent without migrating historical records. Keep ratings, automation markers, and issue guidance unchanged, and document the paired renderer and producer/report proof.
@clawsweeper

clawsweeper Bot commented Sep 2, 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 P2 Normal priority bug or improvement with limited blast radius. proof: sufficient Contributor real behavior proof is sufficient. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Sep 2, 2026
@clawsweeper

clawsweeper Bot commented Sep 2, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed September 2, 2026, 1:41 AM ET / 05:41 UTC.

ClawSweeper review

What this changes

The PR adds an explicit next-step assessment to review decisions so non-action routing text no longer creates a remaining merge-checklist item.

Regression provenance

Possible regression — probable (reviewed change; known regression link). No predecessor PR is attributed.

Merge readiness

✅ Ready for maintainer review

This PR remains necessary because current main still derives merge work from routing prose. The introduced typed-intent path is coherent, preserves conservative handling for legacy reports, and has focused coverage without a discrete correctness defect found.

Priority: P2
Reviewed head: 57de5d52eed4202200b28e10da0a76e21bff5ea8

Review scores

Measure Result What it means
Overall readiness 🦞 diamond lobster (5/6) A focused, well-covered review-rendering fix with direct before-and-after behavior evidence.
Proof confidence 🦞 diamond lobster (5/6) ✨ media proof bonus Sufficient (screenshot): The supplied after-fix evidence exercises the compiled production renderer with identical serialized reports and separately exercises parser-to-report persistence-to-rendering, observing the false baseline count disappear while required-action and blocker controls remain.
Patch quality 🦞 diamond lobster (5/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Verified Sufficient (screenshot): The supplied after-fix evidence exercises the compiled production renderer with identical serialized reports and separately exercises parser-to-report persistence-to-rendering, observing the false baseline count disappear while required-action and blocker controls remain.
Evidence reviewed 6 items Current-main behavior: The fetched main revision still derives checklist work from free-form next-step prose and has no typed next-step assessment input, so the central problem is not already implemented.
Canonical report validation: The new reader accepts only a unique, valid leading frontmatter value and falls back to legacy inference for malformed, duplicated, or competing metadata.
Checklist behavior: Explicit required intent is rendered directly, explicit none suppresses only this derived checklist item, and absent legacy metadata retains the existing prose heuristic.
Findings None None.
Security None None.

How this fits together

ClawSweeper converts review decisions into durable reports and public pull-request checklists. This change carries a typed next-step assessment through parsing and report storage into the checklist renderer.

flowchart LR
A[Review decision] --> B[Decision parser]
B --> C[Durable report]
C --> D[Next-step reader]
D --> E[Checklist renderer]
E --> F[Merge readiness comment]
Loading

Before merge

None.

Agent review details

Security

None.

Review metrics

Metric Value Why it matters
Changed surface 15 files; +1069/-11 lines The change spans the decision contract, durable report path, renderer, focused tests, and proof documentation.
Controlled behavior cases 10 paired renderer cases + 1 producer round trip The supplied proof exercises the reported regression and preservation controls through the compiled rendering path.

Technical review

Best possible solution:

Use typed producer-owned intent for new reports while retaining the conservative prose fallback for historical reports that lack valid metadata.

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

Yes. The submitted paired replay gives a concrete current-head path: render the same serialized report through baseline and candidate renderers and compare checklist and readiness counts.

Is this the best way to solve the issue?

Yes. Carrying explicit intent through the decision and report boundary is narrower and safer than adding phrase-specific exclusions to the existing prose heuristic.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 43553c96ab2f.

Labels

Label changes:

  • add P2: This is a bounded correctness fix for maintainer-facing review readiness output.
  • add proof: sufficient: Contributor real behavior proof is sufficient. The supplied after-fix evidence exercises the compiled production renderer with identical serialized reports and separately exercises parser-to-report persistence-to-rendering, observing the false baseline count disappear while required-action and blocker controls remain.
  • add proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence. The supplied after-fix evidence exercises the compiled production renderer with identical serialized reports and separately exercises parser-to-report persistence-to-rendering, observing the false baseline count disappear while required-action and blocker controls remain.
  • add rating: 🦞 diamond lobster: Overall readiness is 🦞 diamond lobster; proof is 🦞 diamond lobster and patch quality is 🦞 diamond lobster.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (screenshot): The supplied after-fix evidence exercises the compiled production renderer with identical serialized reports and separately exercises parser-to-report persistence-to-rendering, observing the false baseline count disappear while required-action and blocker controls remain.

Label justifications:

  • P2: This is a bounded correctness fix for maintainer-facing review readiness output.
  • rating: 🦞 diamond lobster: Overall readiness is 🦞 diamond lobster; proof is 🦞 diamond lobster and patch quality is 🦞 diamond lobster.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (screenshot): The supplied after-fix evidence exercises the compiled production renderer with identical serialized reports and separately exercises parser-to-report persistence-to-rendering, observing the false baseline count disappear while required-action and blocker controls remain.
  • proof: sufficient: Contributor real behavior proof is sufficient. The supplied after-fix evidence exercises the compiled production renderer with identical serialized reports and separately exercises parser-to-report persistence-to-rendering, observing the false baseline count disappear while required-action and blocker controls remain.
  • proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence. The supplied after-fix evidence exercises the compiled production renderer with identical serialized reports and separately exercises parser-to-report persistence-to-rendering, observing the false baseline count disappear while required-action and blocker controls remain.

Evidence

What I checked:

  • Current-main behavior: The fetched main revision still derives checklist work from free-form next-step prose and has no typed next-step assessment input, so the central problem is not already implemented. (src/clawsweeper-report-comment-helpers.ts, 43553c96ab2f)
  • Canonical report validation: The new reader accepts only a unique, valid leading frontmatter value and falls back to legacy inference for malformed, duplicated, or competing metadata. (src/clawsweeper-next-step.ts:27, 57de5d52eed4)
  • Checklist behavior: Explicit required intent is rendered directly, explicit none suppresses only this derived checklist item, and absent legacy metadata retains the existing prose heuristic. (src/clawsweeper-report-comment-helpers.ts:375, 57de5d52eed4)
  • Persistence path: The report writer serializes validated typed intent to canonical next_step frontmatter only when the decision supplies it. (src/clawsweeper-report-document.ts:667, 57de5d52eed4)
  • Regression coverage: Focused tests cover explicit none, required actions including negation and human-owned work, legacy fallback, malformed metadata, independent blockers, and a producer-to-renderer round trip. (test/review-comment-rendering.test.ts:182, 57de5d52eed4)
  • Submitted runtime proof: The PR body records a Node 24 paired replay of ten serialized-report cases plus a parser-to-report-to-renderer round trip, observing the reported false count on the baseline and zero on the candidate while retaining controls. (57de5d52eed4)

Likely related people:

  • Peter Steinberger: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)
  • Martin Cleary: 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.

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

Labels

P2 Normal priority bug or improvement with limited blast radius. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. proof: sufficient Contributor real behavior proof is sufficient. rating: 🦞 diamond lobster Very strong PR readiness with only minor 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