Repository navigation
fix(orchestration): deliver late Steer as the next message - #528
Conversation
|
What: Independent review found no blocking findings on Reviewed the full four-file diff against Cleared paths:
Proof reused from the PR and authorized review brief: failing-before Reviewer: gpt-6.1-sol through the Codex harness in T3 Code, independent of the implementation author. |
|
Independent review: PASS on No actionable findings. In The shared client command path sends |
Thread transfer impact✅ Thread transfer remains within every enforced ceiling.
Baseline: Scenario and decoded snapshot size10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.
Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed. |
What: A Steer arriving after the run ends is delivered once as an ordinary next message on mobile and web/desktop.
Why: #388 preserved target purpose intent in the mobile outbox, and shared server admission rejected it before delivery policy could start the next message.
So what: Independent review passed on
5d339575f73577c88a48e20fd09789478c39fdb8; CI is still running, and the developer owns merge approval.Closes #526.
At server admission, a Steer with no blocking run follows ordinary message admission and uses the current selection when its original purpose intent targeted the ended run. Both current server-resolved sends and older explicit
steer_activecommands use the same path. Active steering, Restart, explicit purpose declarations, and receipt deduplication keep their existing behavior. Mobile receives success through its existing outbox cleanup, so it neither restores the draft nor displays the rejection. Web and desktop use the same target intent and shared server path, so this also aligns their in-flight race.The prior idle-Steer rejection assertion was replaced because it protected the behavior #526 explicitly changes. The new test first captures a pending Steer, ends its run, then submits and replays it, asserting one message, one new run, one provider-start effect, ordinary
turn_startintent and selection provenance. It covers web/mobile and both command formats. A separate idle case preserves Restart rejection. The unchanged active-Steer test and steering completion suite protect running work.Proof
Commands below use this worktree's
node_modules/.bin/vp:vp test run apps/server/src/orchestration-v2/ExecutionPurpose.integration.test.ts -t 'late web/mobile Steer': failed before the production change withPurposeAdmissionError: There is no active run to steer or restart.(target_missing).vp test run apps/server/src/orchestration-v2/ExecutionPurpose.integration.test.ts: 13 passed after the change.vp test run apps/server/src/orchestration-v2/SteeringCompletion.integration.test.ts apps/server/src/orchestration-v2/SelectionRestart.integration.test.ts apps/server/src/orchestration-v2/CommandPolicy.test.ts: 72 passed.vp test run apps/mobile/src/state/thread-outbox.test.ts apps/mobile/src/state/use-thread-outbox-drain.test.ts packages/client-runtime/src/operations/commands.test.ts: 102 passed.cd apps/server && ../../node_modules/.bin/tsc-rs --noEmit: exit 0, no errors; Effect suggestions only.vp lint apps/server/src/orchestration-v2/Orchestrator.ts apps/server/src/orchestration-v2/ExecutionPurpose.integration.test.ts apps/mobile/src/state/use-thread-composer-state.ts: exit 0; warnings on unchanged code only.vp fmt --checkon those three files anddocs/map.md: passed.git diff --check: passed.No repo-wide checks, simulators, browsers, apps or live data were used. No visual layout changes. No package version bump, per repository policy. Website/SEO impact: none, this changes shared message admission only. Independent review passed on the exact PR head: findings, with
review/independent=successposted bylukemaj. CI is still running.Upstream first: inspected upstream main
1451e7cb23034d29774338608368a15d8845df36's mobile outbox and orchestrator and searched open PRs/Issues for Steer. Upstream lacks this fork-only purpose rejection; no matching upstream fix found. Details and starting-state evidence: #526 (comment).Elon record
Requirements and who asked: #526 and the user require late Steer to send once without draft restoration/error, unchanged active steering, cross-client alignment, red/green proof, scoped tests/typecheck and one PR against main.
Deleted: Rejection of a Steer with no running work; no client retry, new transport, Spec, version bump or app launch.
Bottleneck: Shared server purpose admission rejected the message before the existing delivery fallback.
Checked myself: #526, relevant #388 diff, mobile outbox/composer, shared client commands, web/desktop send path, upstream sources/searches, focused failing-before test, passing scoped suites and server typecheck.
Implemented by gpt-6.1-sol at medium effort through Codex in T3 Code.