Expand description
The end of a container agent’s provider session (SPEC_HISTORY_COMPACT_FORM_ONLY_2026_11_23.md section 5.4).
A container agent’s session files are in its container’s volume, not on the host. The end of a session is the host
path’s (transcript::provider_end::end_session: prove against the store, import what it lacks, verify, remove), run
on a staged copy of the session’s two paths, with the removal done in the container by session id:
- the session’s files are copied out of the container into an owner-only folder of the host’s temp area;
- the proof and the import run on that copy, as for a host agent;
- when the proof has passed, the caller’s admission is taken (the agent’s lease: a running agent holds it, so its
session is never touched), the container’s files are copied out a second time and must equal the first copy,
and only then is
<sid>.jsonland<sid>/removed in the container: through an exec when it runs, through a short helper container on the volume when it is stopped (ContainerManager::session_files_remove); - the staged copy is overwritten and removed, and its folder with it, whatever the outcome.
Nothing here decides when a session ends or which ids AgentMux started: the caller names one session of one container. Like the host path it removes by exact session id and never lists or sweeps a folder.
Structs§
- Docker
Home - A container reached through the container runtime.
Traits§
- Container
Home - Where a container’s session files can be reached. Blocking, and called from a blocking thread:
DockerHomeis the container; a test’s is a folder.
Functions§
- end_
container_ session - Prove, import and remove one session of a container agent: see the module’s text.
readare the zones that may hold the conversation andzoneis where what the store lacks is imported, as forend_session;admitis the caller’s last word, run after the proof and before anything is removed (anErrstops with nothing removed; what it returns is held until the removal is done). A session the container no longer holds is already ended:Okwith nothing counted. Every failure removes nothing, in the container or here.