Expand description
Bounded subprocess execution.
The watchdog tick holds the D1 lock while driving osascript (escalate)
and claude -p (agentinit). If either hangs, the lock ages past its
stale threshold and a concurrent tick force-releases it, entering the
tick path twice. Every subprocess held under a lock must be bounded.
run_bounded spawns the child, drains its pipes on dedicated threads,
polls try_wait on the main thread, and kills + reaps on timeout.
Structs§
- Bounded
Output - Result of a time-bounded subprocess run.
Functions§
- run_
bounded - Run
cmdto completion ortimeout, whichever comes first.