Expand description
Background monitor daemon.
Spawns a detached child process that owns the coding agent: it launches
the agent, captures its stdout and exit code into .devflow/, and — when
the agent exits — runs devflow advance to advance the stage machine.
Owning the agent is the key fix over a CLI-scoped capture thread: because
the monitor outlives devflow start, the agent’s stdout keeps flowing into
the capture file and its exit code is still reaped after the CLI exits.
This is the core automation primitive — no cron, no scheduler, no agent cooperation needed.
Enums§
- Monitor
Error - Errors produced by monitor operations.
Functions§
- spawn_
monitor - Spawn a background monitor that owns the agent for the given workflow state.
- wait_
for_ agent_ pid - Poll for the agent PID that the monitor records, for up to ~1 second.