Repository navigation
refactor(ui): selected-session sends; delete exact-run steer machinery - #125862
Conversation
…chinery browser no longer chooses or persists run targets; steer sends ride the generic durable outbox with queueMode steer and no expectedRunId/expectedLeafEntryId; deletes steer-lifecycle.ts, steered-chip.ts, kind:"steered", steerTargetRunId, sendState:"steering", target-bound retry, uniqueness failure rows; persisted outbox rows normalize at load; net -625 production LOC.
|
🦞👀 Pull request received. I will update this pull request when review starts. |
|
Codex review: needs maintainer review before merge. Reviewed August 18, 2026, 11:24 AM ET / 15:24 UTC. ClawSweeper reviewWhat this changesThis PR removes browser-side exact-run steering and sends selected-session follow-ups through the durable outbox with an explicit queue mode. Regression provenancePossible regression — probable (reproduction; reviewed change; known regression link). No predecessor PR is attributed. Merge readinessKeep open for maintainer review: the UI now defers start-versus-steer to the Gateway’s atomic owner and no blocking patch defect was found, but the persisted browser-outbox migration still lacks the requested reload-and-retry proof. Priority: P2 Review scores
Verification
Live VerificationCommand: Result: PASS (completed) Assertions:
How this fits togetherThe Control UI turns a composer action into a durable browser outbox row and sends it to the Gateway. The Gateway then atomically injects into an active run or starts a new turn, returning the resulting chat state to the UI. flowchart LR
A[Operator message] --> B[Control UI composer]
B --> C[Durable browser outbox]
C --> D[Chat send request]
D --> E[Gateway start-or-steer decision]
E --> F[Active run injection]
E --> G[New session turn]
F --> H[Updated chat transcript]
G --> H
Decision needed
Why: The normalizer changes durable browser rows, while the provided live recording demonstrates active and idle routing rather than the persisted upgrade path. Before merge
Agent review detailsSecurityNone. PR surfaceSource -625, Tests -2056, Other -1. Total -2682 across 38 files. View PR surface stats
Review metrics
Stored data modelPersistent data-model change detected: Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Keep one Gateway-owned start-or-steer path and land the UI cleanup after a sanitized old-row reload-and-retry proof confirms the durable upgrade path. Do we have a high-confidence way to reproduce the issue? No live reproduction was run in this read-only review; yes at source level, because current-main UI still carries exact-run steering while this head sends queue mode directly to the Gateway. Is this the best way to solve the issue? Yes for the runtime boundary: current main makes the Gateway the atomic start-or-steer owner. The remaining question is upgrade proof for persisted browser rows, not a better code layer. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 07a0b5170343. LabelsLabel changes:
Label justifications:
EvidenceWhat 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 (1 earlier review cycle)
|
|
Maintainer decision: accept the source-level persisted-row migration proof for merge and skip the optional legacy-row reload-and-retry recording. The codec/persistence coverage loads retired steer fields, verifies normalization to the generic CI: https://github.com/openclaw/openclaw/actions/runs/32153546302 |
|
Merged via squash.
|
…chinery (openclaw#125862) browser no longer chooses or persists run targets; steer sends ride the generic durable outbox with queueMode steer and no expectedRunId/expectedLeafEntryId; deletes steer-lifecycle.ts, steered-chip.ts, kind:"steered", steerTargetRunId, sendState:"steering", target-bound retry, uniqueness failure rows; persisted outbox rows normalize at load; net -625 production LOC.
What Problem This Solves
With the Gateway owning atomic start-or-steer (#125808), the browser's exact-run machinery (run-target resolution, steered chips, target-bound retry, steering states, expectedRunId production) is obsolete duplicate policy that produced client-side failures like #125427.
Why This Change Was Made
The selected session key is the complete browser-side target; the Gateway decides steer-vs-start (#125808). The UI keeps one generic durable outbox path (offline/reconnect, attachments, idempotency, FIFO) with a queue-mode marker.
User Impact
Steer/busy sends can no longer fail client-side with "The active run could not be identified uniquely"; retry is idempotent and generic; queue-row Steer and modified Enter request steer mode only; Stop remains descendant-aware. Persisted queue rows from earlier builds normalize at load (steered→queueMode steer).
Evidence
Production +296/−921 (net −625), tests +209/−2265; 77→61 steer-grep accounting with per-file disposition (in the maintainer's review notes); focused suites 743+22+346 tests green; ui:build, check-changed, i18n baseline green; #125428 descendant-only regression byte-identical; codex autoreview clean; ratchet baseline shrink-only. Live Control-UI proof (isolated dev gateway + video) to be attached before ready-for-review.
Live proof (isolated dev gateway)
OPENCLAW_STATE_DIRdev gateway on port 19873, this PR's dist + Control UI build (assetindex-CR4ZlzsR.js),anthropic/claude-opus-5live model, fresh dashboard session.sleep 4x8 as separate exec tool calls (>=32s if completed) was steered mid-run; gateway diagnosticreason=active_run_injectedrecorded for the steermessageId(session keyagent:dev:dashboard:f5f37073...); the run stopped after ~11s and ended with the steered marker in the same turn ("Worked for 11s", screenshot 04)./steer: rendered a "Steered." notice, payload became a visible normal turn, answered in 3s (screenshot 05) — no dead end.chat.sendcarriedqueueMode: "steer"+idempotencyKeyand noexpectedRunId/steerTargetRunId; the retired client-side failure row ("The active run could not be identified uniquely") cannot render (locator assert).steer-proof-125862.mp4