fix(workflow): publish hot-intake review comments - #1189
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. |
|
@clawsweeper review |
|
🦞🧹 I asked ClawSweeper to review this item again. |
|
Codex review: needs maintainer review before merge. Reviewed August 17, 2026, 9:56 AM ET / 13:56 UTC. ClawSweeper reviewWhat this changesThe PR routes broad hot-intake sweeps through the existing selected review-comment publisher and adds routing and replay-idempotency coverage. Regression provenancePossible regression — probable (reproduction; failure trace). No predecessor PR is attributed. Merge readinessCurrent main still lacks the hot-intake publication guard; this PR supplies the narrow repair with strong exact-head proof and no actionable patch finding. Priority: P1 Review scores
Verification
How this fits togetherThe sweep workflow reviews items, writes canonical records, then selects a terminal route to publish durable GitHub review comments. This change connects hot-intake output to the selected-comment route while retaining the background route for non-hot work. flowchart LR
A[Hot-intake dispatch] --> B[Planner]
B --> C[Review artifacts]
C --> D[Canonical review records]
D --> E{Terminal publication route}
E --> F[Selected comment sync]
E --> G[Background comment sync]
F --> H[Durable GitHub comment]
G --> H
Before merge
Agent review detailsSecurityNone. Review metrics
Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Land the narrow guard with its route matrix and retain focused publication proof when the hot-intake planner contract changes. Do we have a high-confidence way to reproduce the issue? Yes—source shows a no-item broad hot intake was excluded from both terminal-comment routes, and the PR provides an exact-head route/publication proof. Is this the best way to solve the issue? Yes—the patch reuses the existing selected-comment publisher, fencing, and idempotency behavior rather than introducing parallel publication. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 335cb45ceb16. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (5 earlier review cycles)
|
fe30367 to
4c4decc
Compare
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
@clawsweeper re-review |
|
🦞👀 Re-review progress:
|
Summary
Problem
The broad
workflow_dispatchhot-intake path has noitem_numberoritem_numbersinput. After its review artifacts were committed,Dispatch background review comment syncexcluded hot intake whileSync selected review commentsrequired an explicit item or a non-target repository dispatch. Both terminal-comment routes therefore evaluated false.This was observed on openclaw/openclaw#125204: intake and the model/artifact run completed, but the broad hot workflow skipped both comment-sync steps. Its valid start lease then delayed the exact worker until expiry; the terminal response was eventually published roughly 38 minutes after issue creation.
Implementation
Sync selected review commentsnow also selectsneeds.plan.outputs.hot_intake == 'true'. It reuses the existing target-write token, sync implementation, canonical state publication, action ledger, fencing, retry, and idempotency behavior. No queue, lease, credential, or publication implementation changes are introduced.The regression asserts exactly one terminal sync route for:
It also executes the real
apply-decisions --sync-comments-onlyboundary twice against controlled GitHub state: the first pass publishes the final ClawSweeper comment and the replay is a no-op. Existing lease/fencing and immutable-ledger suites remain unchanged and pass.Validation
pnpm run build:allreview publication routes hot intake once without changing other producersnode --test --test-concurrency=1 test/sweep-workflow.test.ts— 121/121 passed on Linuxpnpm exec oxfmt --check .github/workflows/sweep.yml test/sweep-workflow.test.ts.github/workflows/sweep.ymlgit diff --check origin/main...HEADReal Behavior Proof
Claim: A no-item broad hot-intake run selects the synchronous terminal-comment route exactly once; it does not select the background route. Other producer routes retain their prior ownership.
Exercised surface: exact committed
.github/workflows/sweep.yml, its parsed GitHub Actions conditions, the real selectedapply-decisions --sync-comments-onlypublication boundary, and the existing lease/fencing/idempotency suites.Scenario/fixture: the routing matrix evaluates production event/input shapes for hot and normal workflow dispatch, explicit items, target and exact repository dispatch, and schedule. A controlled openclaw/openclaw#125204-shaped record begins with a stale bot comment; the selected sync runs twice through the real apply entry point against a stateful
ghboundary.Command/environment: AWS Crabbox Linux (
c7a.8xlarge), provideraws, runrun_89cc583b9849, leasecbx_c29a3f86d9f1, exact head4c4deccf2a6beff08c7d5f1478ea1fc2ac0f5b0c, base69adf7592803cc1440162b049fbf572be66fdd12. Both changed files were SHA-256 checked against their committed blobs before execution.Observed result: before: broad hot intake
selected=false,background=false; after:selected=true,background=false. The first real apply pass performed one final-comment mutation; the replay performed none, leaving exactly one terminal ClawSweeper comment. All 121 workflow tests, four lease/fencing tests, two ledger idempotency tests, formatting, YAML parse, pinned actionlint, and exact-content checks passed.Artifact/trace: Crabbox run
run_89cc583b9849, leasecbx_c29a3f86d9f1; terminal proof line:CSW-132 Linux hot-intake publication boundary proof: PASS.Live GitHub Actions proof: With Martin's explicit authorization, one bounded real
workflow_dispatchran on this PR branch and exact head: run32035557210. Inputs werehot_intake=true,target_repo=openclaw/slacrawl,batch_size=2,shard_count=1, noitem_numberoritem_numbers, andapply_existing=false/apply_after_review=false. The planner selected only openclaw/slacrawl#152, reported planned count 1 below its effective capacity 44, and therefore skipped continuation. Its model review completed, artifact publication succeeded,Dispatch background review comment syncwas skipped, and the fixedSync selected review commentssucceeded. The realapply-decisions --sync-comments-onlyresult was exactlyreview_comment_synced: 1; it updated the existing durable ClawSweeper comment on #152 at 2026-08-17T13:35:41Z. No close/apply operation ran, no issue-implementation candidate existed, and the optional live-proof dispatcher found no enabled proof request.Limits: The live proof deliberately used a single public PR outside openclaw/openclaw to avoid the enabled issue-implementation producer. It proves the actual GitHub Actions condition, branch-loaded workflow, target token, canonical record path, callback, and final comment publication once. The deterministic matrix supplies the replay/no-double-publish guarantee. The optional
pr-behavior-proofskill named by workspace policy was unavailable in this session, so its contract is reproduced explicitly here.Current review infrastructure status: The current-head
@clawsweeper re-reviewcommand was accepted after this proof, but its normal comment-router run failed before a verdict when GitHub returned HTTP 503 to its authenticatedgh api usercheck. A direct authenticated API check from the operator host reproduced the same 503, while the PR remainsCLEANat the exact head above. This is an infrastructure-only review blocker, not a patch finding. No duplicate review command, manual workflow rerun, queue action, deployment, or production control change will be made; the next step is the normal current-head/current-body re-review after GitHub API recovery.Reviews
69adf7592803cc1440162b049fbf572be66fdd12: clean; confirmed the selected route, mutually exclusive background route, and replay idempotencydecision=keep_open,confidence=high,action=kept_open; no GitHub mutationRisks and rollout
Risk is limited to broad hot-intake result publication. A successful hot run can now perform the same bounded selected-comment sync already used by exact/explicit producers. The matrix guards against double publication and unintended changes to target, exact, scheduled, and normal broad routes.
Rollback is a one-line revert removing the hot-intake disjunct from the selected-sync condition. No state migration or queue repair is required.
This PR changes a GitHub Actions workflow and therefore requires maintainer credentials with workflow scope to update. It does not address the separate OpenClaw Bay projection timeout/fail-closed behavior or the durable-lifecycle over-cap condition.
Related