Repository navigation
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. |
|
Codex review: needs changes before merge. Reviewed August 18, 2026, 7:17 PM ET / 23:17 UTC. ClawSweeper reviewWhat this changesThis PR removes Regression provenancePossible regression — suspected (reviewed change). No predecessor PR is attributed. Merge readinessKeep open: a rejected history predecessor is added to the web client’s authoritative tracker before its adoption guard runs, allowing a later stale observer digest to replace newer session status. Priority: P1 Review scores
Verification
Live VerificationEntry: Result: FAIL (partial) — step 5 Steps:
Recorded live on the PR head ( How this fits togetherGateway session rows expose aggregate activity, while chat clients retain exact run identities from history snapshots and lifecycle events. Those identities control terminal reconciliation and observer-status rendering. flowchart LR
A[Gateway history snapshot] --> B[Web history loader]
C[Newer lifecycle start] --> D[Local run tracker]
B --> E{Snapshot admitted?}
E -->|Accepted| D
E -->|Rejected| F[Discard predecessor identity]
D --> G[Observer authority check]
G --> H[Visible chat status]
Before merge
Findings
Agent review detailsSecurityNone. Review metrics
Stored data modelPersistent data-model change detected: Root-cause clusterRelationship: Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Merge-risk optionsMaintainer options:
Copy recommended automerge instructionTechnical reviewBest possible solution: Admit a web history snapshot into the local tracker only after it passes the same ownership fence as the Android implementation, with a deferred predecessor/successor regression test. Do we have a high-confidence way to reproduce the issue? Yes, from source: start a history request, receive a successor lifecycle start, resolve history with an active predecessor, then deliver that predecessor’s observer digest while no foreground run ID is set. Is this the best way to solve the issue? No: the web path needs the same rejected-snapshot ownership fence already applied to Android, otherwise it registers an identity its own adoption decision rejects. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against ffbbb6417871. LabelsLabel justifications:
EvidenceAcceptance criteria:
What I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (3 earlier review cycles)
|
…wner facts Session rows no longer project a run-id list. Consumers migrate to the facts their owners record: event-local run ids for terminal reconciliation (with a reload-scoped local run tracker preserving the stale-terminal defense: unknown terminals are ignored, predecessor terminals keep the row running while tracked runs remain), chat.history in-flight identity for snapshot recovery, request-local send/run ids for token and projection restore, digest-owned ids for observer authority. The silent activeRunIds[0] fallbacks are gone, as is the incoherent hasActiveRun:true/empty-list state; resolveVisibleActiveSessionRunState shrinks to the boolean facts its callers need. Android and Apple mirror the same migration with their pendingRuns tracking. The field was never in the protocol schema, never stable-shipped to native clients, and has no plugin consumers.
caa8102 to
1785f41
Compare
|
@clawsweeper address review Please apply the current review finding only: move Control UI history-run tracker admission behind the successful in-flight snapshot ownership/adoption fence, add the deferred predecessor-versus-successor observer regression, and rerun the focused Control UI tests. Do not merge yet; live selected-session proof and final maintainer landing will follow. |
|
🦞🔧 Reason: repair commands require a ClawSweeper PR or a PR opted into ClawSweeper autofix or automerge. Supported re-review commands work on open issues and PRs: |
|
@clawsweeper stop Independent owner review found broader active-set and terminal/observer projection gaps beyond the queued web fix. Stop automation; this PR should not merge until the producer contract is reconsidered. |
|
🦞✅ I added |
|
Maintainer decision: closing this refactor rather than continuing to patch the client-local replacement for The core premise does not hold under overlapping and cross-client runs. The supported direction is narrower and owner-backed: keep What would change this decision: an owner-level Gateway contract that supplies a complete active-set generation and run-scoped terminal/observer projection, with web, Android, and Apple boundary proofs for overlap, reconnect, hidden sessions, and cross-client starts. More client-local tracker patches are not sufficient. |
Session rows no longer emit activeRunIds: [] while hasActiveRun is true. Presence now means the complete exact set of direct run ids; omission means identities are unavailable (projected/embedded owners); [] only ever represents proven idle. Consumers stop guessing: soleActiveSessionRunId() replaces the arbitrary [0] fallbacks in the observer digest, transcript cache key, activity inspector, and stale-terminal reconciliation, each falling back to its owner fact. Follows the maintainer direction from #125983: the field stays as Gateway-owned exact facts; producer-side liveness/observer projections are a named follow-up.
#126106) * fix(gateway): make activeRunIds presence mean a complete exact run set Session rows no longer emit activeRunIds: [] while hasActiveRun is true. Presence now means the complete exact set of direct run ids; omission means identities are unavailable (projected/embedded owners); [] only ever represents proven idle. Consumers stop guessing: soleActiveSessionRunId() replaces the arbitrary [0] fallbacks in the observer digest, transcript cache key, activity inspector, and stale-terminal reconciliation, each falling back to its owner fact. Follows the maintainer direction from #125983: the field stays as Gateway-owned exact facts; producer-side liveness/observer projections are a named follow-up. * fix(gateway): clear unavailable active run ids in events * fix(gateway): preserve idle active run sets * fix(clients): close active run id cache gaps * test(android): isolate history run snapshot
openclaw#126106) * fix(gateway): make activeRunIds presence mean a complete exact run set Session rows no longer emit activeRunIds: [] while hasActiveRun is true. Presence now means the complete exact set of direct run ids; omission means identities are unavailable (projected/embedded owners); [] only ever represents proven idle. Consumers stop guessing: soleActiveSessionRunId() replaces the arbitrary [0] fallbacks in the observer digest, transcript cache key, activity inspector, and stale-terminal reconciliation, each falling back to its owner fact. Follows the maintainer direction from openclaw#125983: the field stays as Gateway-owned exact facts; producer-side liveness/observer projections are a named follow-up. * fix(gateway): clear unavailable active run ids in events * fix(gateway): preserve idle active run sets * fix(clients): close active run id cache gaps * test(android): isolate history run snapshot

What Problem This Solves
Session rows projected an implementation list of run ids that was never in the protocol schema, never stable-shipped to native clients, had zero plugin consumers, and could be incoherent (
hasActiveRun: truewith an empty list — its producer only readschatAbortControllers). Browser exact-run steering was its main consumer and is gone (#125808/#125862/#125921); the rest read it for facts their owners already record.Why This Change Was Made
Record facts where they happen, read them where needed. Terminal reconciliation uses event-local run ids plus a reload-scoped local run tracker that preserves the stale-terminal defense (unknown terminals ignored; predecessor terminals keep the row running while tracked runs remain — regression-tested, fails pre-fix); history recovery uses
chat.history's in-flight identity; token/projection restore uses request-local ids; observer authority uses digest-owned ids; the silent[0]fallbacks are deleted. Android/Apple mirror via theirpendingRunstracking.User Impact
Behavior-neutral by design; removes a stale-terminal wrong-state window that the old membership check masked only when the list was populated.
Evidence
Production +96/-355 pre-fix pass, final total +557/-927 across gateway/UI/Android/Apple; UI focused 584 + lifecycle/recovery e2e 10, broad UI 9,957 passed, Android full unit matrix passed, Apple ChatViewModel 279 passed,
protocol:check/build/ui:buildgreen, autoreview clean (0.96). Local macOS tooling-shard stall documented as env-only (hosted CI judges).