Skip to content

feat(compass-e2e): dogfood harness leg 5 — persist + resume across a container boundary (SEA-1789 H5) - #212

Open
seal-agent wants to merge 2 commits into
seal-1788-h4-legs34from
seal-1789-h5-persist-resume
Open

feat(compass-e2e): dogfood harness leg 5 — persist + resume across a container boundary (SEA-1789 H5)#212
seal-agent wants to merge 2 commits into
seal-1788-h4-legs34from
seal-1789-h5-persist-resume

Conversation

@seal-agent

@seal-agent seal-agent commented Aug 7, 2026

Copy link
Copy Markdown
Contributor

This PR is part of a stack containing 3 PRs:

  1. main
  2. feat(compass-e2e): script canned-model tool_calls turns for the dogfood harness (SEA-1787 gap-2) #208
  3. feat(compass-e2e): dogfood harness legs 3+4 — spawn + cross-agent messaging (SEA-1788 H4) #211
  4. "feat(compass-e2e): dogfood harness leg 5 — persist + resume across a container boundary (SEA-1789 H5)" (this PR)

Adds the leg-5 persist+resume scenario to the dogfood e2e harness: run a
turn, tear the agent's container down, provision a fresh container, and
resume the logical session into it, asserting the durable transcript
lineage carried across the boundary.

  • go/e2e/agent_ops.go: new Resume(ctx, containerName, resumeSessionID,
    initialPrompt) primitive, mirroring StartSession but setting
    ResumeSessionId. Returns the server-minted live session id (a new id —
    the durable transcript stays keyed under the original logical id).
  • go/e2e/legfive_test.go: TestLegFivePersistAndResume. //go:build podman,
    podmanUsable() skip-guarded (present-but-skipped RED like leg-2/leg-3/4;
    green gated on the assembled agent image + the full agent-lane). Two
    distinct canned replies drive the pre-teardown and resumed turns; the
    transcript under the ORIGINAL logical session id must carry BOTH replies
    (resume loaded the reconstructed body, not a fresh session), and the
    resumed lifetime's minted id must differ from the original (the
    control-plane live id is separate from the durable transcript key).

The carried transcript is asserted under the original session id, not the
minted resume id: entry_seq is monotonic per logical session across resumes
and BindLifetime rebases the new lifetime's frames onto that stable key, so
querying the minted id would be a silent false-green.

Refs SEA-1789

Co-authored-by: Matt Wilkinson matt@sealedsecurity.com

…container boundary (SEA-1789 H5)

Adds the leg-5 persist+resume scenario to the dogfood e2e harness: run a
turn, tear the agent's container down, provision a fresh container, and
resume the logical session into it, asserting the durable transcript
lineage carried across the boundary.

- go/e2e/agent_ops.go: new Resume(ctx, containerName, resumeSessionID,
  initialPrompt) primitive, mirroring StartSession but setting
  ResumeSessionId. Returns the server-minted live session id (a new id —
  the durable transcript stays keyed under the original logical id).
- go/e2e/legfive_test.go: TestLegFivePersistAndResume. //go:build podman,
  podmanUsable() skip-guarded (present-but-skipped RED like leg-2/leg-3/4;
  green gated on the assembled agent image + the full agent-lane). Two
  distinct canned replies drive the pre-teardown and resumed turns; the
  transcript under the ORIGINAL logical session id must carry BOTH replies
  (resume loaded the reconstructed body, not a fresh session), and the
  resumed lifetime's minted id must differ from the original (the
  control-plane live id is separate from the durable transcript key).

The carried transcript is asserted under the original session id, not the
minted resume id: entry_seq is monotonic per logical session across resumes
and BindLifetime rebases the new lifetime's frames onto that stable key, so
querying the minted id would be a silent false-green.

Refs SEA-1789

Co-authored-by: Matt Wilkinson <matt@sealedsecurity.com>
@linear-code

linear-code Bot commented Aug 7, 2026

Copy link
Copy Markdown

SEA-1789

…ency, redundant-pin note (SEA-1789 H5)

Two comment-precision fixes from review (both non-gating lows, comment-only,
no behavior change):

- reply1 assertion: the prior comment overclaimed that a fresh-load resume
  would make reply1 ABSENT. reply1's durable row survives RemoveWorkspace
  regardless (RemoveWorkspace does not prune the transcript); its
  discrimination is contingent on lifetime-2's start-checkpoint carrying the
  reconstructed body forward. Reworded to state that contingency and to note
  the primary rebase-onto-logical-id proof is the reply2 assertion.
- resumedSessionID != "" guard: noted it is an explicit contract statement
  for the reader, since AwaitSessionSettled on resumedSessionID above would
  already fail an empty id before this point.

Refs SEA-1789

Co-authored-by: Matt Wilkinson <matt@sealedsecurity.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant