Repository navigation
Conversation
…gent Stacked on #4903 (the un-gated half of #4893). Restores the session.stop control action: the Stop button for any loaded session by id, at the same trust level as session.create / session.archive, with no confirmation. Product decision (2026-09-11): the safeguard is attribution, not a gate — "Session stopped: <title> — Requested by <agent session>" as a toast and a notification-center entry with a View action, plus the control narration. Idle -> {ok:true, alreadyIdle:true}; unknown id -> structured error; the target_working hint points agents at session.stop again. This is Warden finding 2AY-HF9 (stop by id without confirmation) and is intentional; it needs one human approving review. Signed-off-by: Guillaume Loret <[email protected]>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Test evidence — agents see which sessions are working, an agent's archive of a working session is refused through its own channel while the person keeps a simple confirmation, and session.stop is attributed — ✅ passedSHA ba8b199 · sandbox ref ba8b199 · engine v1 ✅ 0/2 screenshots passed · 0 expectations passed · 0 failed · 0 pending [world] desktop(daytona) · mock(mcp) · workspace(/tmp/openwork-session-archive-1789155054413-79651-a) · [seed:raw] evalIn() ×23 ⚪ UNVALIDATED — 1. agents see which sessions are working, an agent's archive of a working session is refused through its own channel while the person keeps a simple confirmation, and session.stop is attributed artifact 1
⚪ UNVALIDATED — 2. agents see which sessions are working, an agent's archive of a working session is refused through its own channel while the person keeps a simple confirmation, and session.stop is attributed artifact 2
Test run created 2026-09-11T19:28:59.257Z · Source: |


Stacked on #4903 (the un-gated half of #4893). This PR is exactly the part of #4893 that Warden flagged (2AY-HF9, previously NLX-3N2:
session.stopcan interrupt any loaded session without confirmation) and therefore the only part that needs a human approving review. Its tree is byte-identical to #4893's head7bd7f33e0; #4893 is closed as superseded by #4903 + this PR.What it adds (296 lines, one feature)
session.stop { sessionId }— the Stop button for any loaded session by id. User decision (2026-09-11 12:35): "an agent should be able to stop a session if a user asks him to do so", same trust level assession.create/session.archive, no confirmation.{ok:true, alreadyIdle:true}; success →{ok:true, stopped:true, sessionId, title}; unknown id → structured error. Not chained into archive.open-sessionnotification action), plus the control-action narration.stopOnlyinuse-session-archive.tsx); v2 preview disabled with its own reason.target_workinghint and thesession.archivedescription point agents atsession.stopagain ("call session.stop first, then archive"); docs step 2 "Stop when you ask for it" returns.What Ben is approving
The product decision that an agent may stop another session's work without a confirmation dialog, with attribution as the only safeguard. Everything else in #4893 merges independently through #4903. If the "who may stop whose work" question is re-opened, this PR is the one to park; #4903 does not depend on it.
Verification (head
ba8b199e7)bun test --isolate tests/session-archive-agent-contract.test.tsx tests/notification-store.test.ts(apps/app)session.stopcases + 7 store)tsc --noEmit(apps/app)pnpm evals:e2e session-archive-agent-requester(OPENWORK_EVAL_DAYTONA=1 OPENWORK_EVAL_REF=ba8b199e7…)The e2e step this PR owns: an agent stops working B by id from A1 → B's run ends (aborts only B), nothing navigates, toast + persisted notification-center entry name target and requester, second stop is
alreadyIdle, unknown id is a structured error. The same spec on #4893's identical tree passed 1/1 on Daytona (7bd7f33e0,refMismatch: false); it is re-run on this head so the evidence is commit-bound.Merge order: #4903 first, then this (GitHub retargets it to
devwhen #4903's branch is deleted).