Repository navigation
fix(review): preserve history across local reruns - #1133
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. |
|
Codex review: needs maintainer review before merge. Reviewed August 12, 2026, 7:03 AM ET / 11:03 UTC. ClawSweeper reviewWhat this changesThe PR persists compatible completed local-review history for exact-item and committed-range reruns so subsequent prompts can reconcile earlier findings. Merge readinessKeep open for normal maintainer review: current main does not contain this local-history behavior, and the submitted implementation is coherent with sufficient focused proof. Priority: P2 Review scores
Verification
How this fits togetherClawSweeper’s local review commands construct Codex prompts from Git and artifact state, then emit reports for later inspection. This change stores completed review context locally and supplies it to compatible later runs while rejecting unrelated, incomplete, or failed state. flowchart LR
A[Local review command] --> B[Artifacts and Git history]
B --> C[Identity and ancestry checks]
C --> D[Previous completed review]
D --> E[Codex review prompt]
E --> F[New local report]
F --> B
Before merge
Agent review detailsSecurityNone. Review metrics
Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Keep local history as a bounded compatibility layer using the existing hosted comment renderer and parser, with incompatible or incomplete state excluded before prompt construction. Do we have a high-confidence way to reproduce the issue? Yes: the checked-in deterministic test defines a current-head success, failure, recovery, changed-base, and unrelated-branch path for this behavior. Is this the best way to solve the issue? Yes: reusing the established hosted review-comment representation avoids a parallel history format while retaining bounded compatibility checks. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against a1795973a9e6. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
History |
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
Summary
Problem
Hosted review carries the latest durable ClawSweeper result into the next review as
previousClawSweeperReview. Local review did not:--local-rangestarted without prior review state, and exact--local-onlyruns did not reuse earlier local results. Repeated local runs were independent reviews, so they could not reliably reconcile fixed findings, earlier dispositions, or genuinely late findings.The implementation now reuses the same bounded hosted representation and parser. History is reconciliation context only; every prompt still requires an independent full inspection.
Implementation
review_status: complete; a failed rerun retains the prior completed bodyClawSweeper feedback disposition
pnpm checkreceipts below.Validation
Current head:
98280ac678bc997d8a62d396605ae0e2df76ce63Base:
a1795973a9e6bb00b73cd6adc21a4ea02ca78cedpnpm run build:allnode --test --test-name-pattern="local exact review history is keyed by repository and item" test/command.test.tsnode --test --test-name-pattern="exact local bootstrap rejects" test/review-command-workflow.test.tsnode --test --test-name-pattern="carries hosted-shaped review history" test/local-range-review.test.tsnode --test test/review-prompt-context.test.ts test/context.test.ts— 30/30 passedpnpm run lint:srcpnpm run lint:scriptsoxfmt --checkon all changed filesgit diff --check origin/main..HEADpnpm run checkin Docker-backed Crabbox — static checks, all builds, all lint lanes, changed coverage, and 248-file full coverage passedThe success → failure → success regression was also run with only the persistence guard temporarily reverted to the prior behavior: it failed because the third prompt received the failed head. Restoring the committed guard made the same regression pass; the worktree was clean afterward.
Real Behavior Proof
--local-onlybootstrap decision; productionreview --local-rangeCLI, Git-backed history discovery, prompt construction, hosted rendering/parsing, base/ancestry invalidation, failure retention, and clean-checkout behavior.98280ac678bc997d8a62d396605ae0e2df76ce63; Nodev24.15.0;provider=local-container; imagemcr.microsoft.com/playwright:v1.60.0-noble; leasecbx_d31caedc3ba6(stopped).build:all, source/script lint, and focused formatting all passed; 14.060 s total.cbx_20ece4f25f1f(stopped).pnpm run checkpassed, including static checks, all builds, all lint lanes, changed coverage, and 248-file full coverage; 261.755 s total.e969dbba2f...are superseded. Only the two current-head leases above support this revision.Review closeout
codex review --uncommitted: clean after each accepted fixcodex review --base origin/main: no actionable correctness defectspnpm run review -- --local-range --target-repo openclaw/clawsweeper --base origin/main:review_status: complete, patch correct, confidence 0.89, no findings; it identified only the then-missing current-head proof, now supplied aboveEPERM); the same builds and tests passed directly and in the exact-head Linux containers aboveRisks, rollback, and OpenClaw Bay impact