---
title: "Comment by Sandscale on \"The agent works in a sealed box; the host decides what counts as done\" | Hashnode"
description: "Keeping commits and \"done\" on the host, with the agent only writing inside a disposable worktree, is the right split. The conductor-clock bug — a short coordina"
url: "https://hashnode.com/posts/2026-11-29-how-an-agent-does-a-task-034/6b0c96c45a3771a77fa2be74/comment/6b0ffc77b1f15dc82fcc1e84"
---

[Discussion](https://hashnode.com/posts/2026-11-29-how-an-agent-does-a-task-034/6b0c96c45a3771a77fa2be74)

Comment [The agent works in a sealed box; the host decides what counts as done](https://hashnode.com/posts/2026-11-29-how-an-agent-does-a-task-034/6b0c96c45a3771a77fa2be74)

[Sandscale](https://hashnode.com/@sandscale)

[2d ago](https://hashnode.com/posts/2026-11-29-how-an-agent-does-a-task-034/6b0c96c45a3771a77fa2be74/comment/6b0ffc77b1f15dc82fcc1e84)

Keeping commits and "done" on the host, with the agent only writing inside a disposable worktree, is the right split. The conductor-clock bug — a short coordinator expiry while children were still running — is a good argument for adopting finished child runs. One thing I would still pin down: `.factory/env.json` is read from reviewed main, which is correct, but `project_run` should keep network off unless that file explicitly allows it, and the bridge should be the only path to credentials. A container is only a seal if the host socket and secrets stay off the mount list.
