Replies: 3 comments
|
Confirmed the archived half against our own tree, with a root cause one layer below where the report places it, and fixed it there. You attribute it to That has a second consequence beyond schedules, which is how we noticed independently: a delete API that refuses while a session is live becomes unsatisfiable, because nothing can stop being live. Archive succeeded, delete refused, and only restarting the host got through. Our fix keeps each handle keyed by session and retires the agent in Two notes for anyone implementing it upstream:
We are not taking the cold-session half. One behaviour change we accepted deliberately, since your report implies it: archiving a session with a turn in flight now stops that turn. |
|
Verified the residency analysis against upstream rc.2 (not a fork), and it holds at every layer. This deserves to be more than a schedule fix — it's the missing retirement primitive for the whole session-lifecycle family. Source confirmation, claim by claim:
The cross-link to the delete design is direct. In #4441 we are designing a One test-harness pattern worth generalizing. Your stub's The cold-session half staying out of scope is the right call — schedules outside agent residency is a delivery-boundary decision, not a fix. But the archived half now has an independent upstream verification, and the delete design in #4441 has its missing precondition identified. |
|
Thanks for verifying it against upstream rather than taking the fork's word — and your stub-divergence point is the most useful thing in this thread, so I took it. On the shared invariant. Agreed that "after dispose: One refinement from doing it. The invariant wants to be an assertion helper the harness exposes rather than a test in one package, because the divergence appears wherever a fake factory does. Ours now goes through On the sequencing generalizing to delete. Yes, and the ordering has a second reason beyond symmetry with storage-first commit: retiring before durability would make a failed archive leave the session stopped, which is worse than a successful archive leaving it briefly running. Whichever step is irreversible for the user should be the one that has already succeeded when the other is attempted. For delete that means storage first, registry second; for archive it means durable archive first, retirement second. I would add one caveat to "the missing retirement primitive for the whole family": archive-retire is a retirement trigger, not the primitive. The primitive is holding the handle at all, and anything else wanting to retire — an idle-eviction policy, a memory-pressure reaper, an explicit close verb — needs the same retained handle and will want its own trigger. If upstream takes this, the handle map is the part worth landing first and separately; the archive call site is one line on top of it. |
Uh oh!
There was an error while loading. Please reload this page.
@deepseek-ai/dsh-scheduleties reminder delivery to whether a rootAgentobject happens to be resident in the process. That runtime-residency condition doesn't line up with what a user thinks "this conversation is active" means, and it produces two opposite surprises.Archived sessions still fire.
WorkspaceApi.archiveSessioncallsctx.workspaceRegistry.archiveSession(sessionId)and returns the updated id set — that's the whole handler. It never touchesctx.agents, and nothing disposes the agent. The client mirrors this: archiving the current session only clears the selection (workspaces-service.client.spec.ts, "Archiving the current session clears it into the New Session view state"). So a session you archived stays resident and itsScheduleRuntimetimers stay armed. A reminder can start a turn in a conversation the user deliberately put away — and it won't be in the sidebar to explain where it came from.Cold sessions never fire.
ScheduleRuntimeinstalls onagent/created, so timers exist only while an agent is resident.ensureSessionmints agents only on a request for that identity, and history reads go through the detached path (persistence.inspect()), which creates no agent. A session nobody opened this run is cold: its reminder sitsoverdueuntil someone opens that conversation, even withdsh webup the whole time.These are the same root cause. Residency is an implementation detail of the agent runtime; Schedule inherited it as a delivery condition, and archive state was never crossed with it.
I don't think
deliveryMode: 'session-local'is wrong as a v1 boundary — the conversational-delivery note is explicit that external delivery "requires a different product boundary." But the archive interaction reads like an unconsidered crossing rather than a deliberate limit. Two things that would help independent of any larger scheduler work:Happy to send a PR for whichever direction maintainers prefer.
All reactions