Hacker News new | ask | show | jobs
by klodolph 50 days ago
Harnesses should be responsible IMO for managing lifecycle stuff, including worktrees and temp files.

It’s simple, deterministic stuff. At least most of the time.

1 comments

Hence my question.

I assume auto-updates are handled by deterministic code that's far away from anything agents can touch (self-modifying harnesses like Autolith notwithstanding). With the same behavior showing up in multiple high-profile harnesses (Codex, Claude Code), it feels likely there must be some actual reason for doing it this way.

I didn’t see your reply.

It should be the harness responsibility to create / destroy things like worktrees and scratch spaces, and communicate to the agent (e.g. via system prompt) where the scratch space is and its purge schedule. Harness should also set appropriate env vars to make this work in tools.

> With the same behavior showing up in multiple high-profile harnesses (Codex, Claude Code), it feels likely there must be some actual reason for doing it this way.

I think fixing it is just not high on the priority list.