Skip to content

ui-server: test that retiring a conversation cancels its hosted compute jobs #3348

Open

Description

@schlessera

Context

Found while delivering #3108 (epic #3103). Hosted compute cancels a conversation's jobs when the session catalog retires it: createApp wraps catalog.retireChat and calls computeHost.cancelSession for each retired session (packages/ui-server/src/app.ts:756-764; cancelSession, packages/ui-server/src/brain/compute-host.ts:185 and :881). But no route calls catalog.retireChat yet; its only callers are the catalog itself and its tests (retireChat, packages/ui-server/src/ws/session-catalog.ts:302-310; packages/ui-server/tests/chat-lifecycle.test.ts). So the cancellation path is untested end to end.

The authenticated deletion endpoint is planned in #3230 (epic #3234), which itself waits on #3229.

Source pointers are on epic/3103-external-compute at 18d859421; the hosted compute code reaches main with #3404.

Scope

When the conversation-deletion route lands, prove through that route that a retired conversation's unsettled hosted compute jobs are cancelled. If retirement takes a different path, wire the cancellation there instead.

Out of scope

Acceptance criteria

  • When the route that retires or deletes a conversation lands, a host-route test proves its unsettled compute jobs are cancelled, their release recorded, and their reservations settled.
  • Or, if conversation retirement takes a different path, the cancellation is wired there instead, with a failing-first test.
  • A mutation that removes the cancelSession call fails the test.

Verification

Keyless host-route test with the offline test provider and disposable state, through bun run test.

Contract impact

None.

Triage 2026-11-03: added source pointers (the existing retireChat wrapper in createApp), named #3230 as the route this waits for, added scope, exclusions, a mutation criterion and verification. Set priority: p2, blocked; attached to epic #3103. Brief complete; agent-ready alongside blocked.

Activity

  1. added
    type: testCoverage, harness or proof work with no behaviour change.
    area: ui-serverHono app factory: turn coordinator, auth, session catalog, routes, cron.
    priority: p2Wanted, not scheduled. Pulled in when a milestone has room.
    blockedWaiting on another issue or an upstream dependency. Say which in the body.
    agent-readyContext and acceptance criteria are complete enough for an agent to take this unattended.
    on Nov 2, 2026
  2. schlessera commented on Nov 3, 2026

    @schlessera
    OwnerAuthor

    Triage 2026-11-03: added blocked with Blocked by #3230. The retireChat → cancelSession wrapper already exists on the epic branch (packages/ui-server/src/app.ts:756-764), but there is no route to drive it until #3230 adds the authenticated deletion endpoint. Attached to #3103.

  3. schlessera commented on Nov 3, 2026

    @schlessera
    OwnerAuthor

    Unblocked: #3230 is closed, so scripts/sync-project.ts is removing the blocked label.

  4. removed
    blockedWaiting on another issue or an upstream dependency. Say which in the body.
    on Nov 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    agent-readyContext and acceptance criteria are complete enough for an agent to take this unattended.area: ui-serverHono app factory: turn coordinator, auth, session catalog, routes, cron.priority: p2Wanted, not scheduled. Pulled in when a milestone has room.type: testCoverage, harness or proof work with no behaviour change.

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions