isSpawnWorking
isSpawnWorking(
agents,cwd):boolean
Defined in: src/json-tolerant.ts:67
Is the verdict spawn at cwd still actively producing output? Only agentStatus === "working"
keeps us waiting; an agent that is gone (not in agents) or in any finished/settled state
(idle / done / blocked / unknown) is treated as no-longer-writing, so a repaired or unparseable
verdict can be acted on immediately rather than after the hard timeout.
NOTE (residual race): agentStatus can briefly flicker to a non-working value during a
partial write, which would let the gate fire early — finalizing a truncated repaired parse as a
false success, or an unparseable partial as a premature failure. This is mitigated (strict parses
are never gated; the verdict file is normally written atomically; the still-working retry
shrinks the window) but not eliminated. The hard timeout in each finalize loop is the true
backstop.
Parameters
Section titled “Parameters”agents
Section titled “agents”object[]
string
Returns
Section titled “Returns”boolean