“The hard part is that every session is behaving reasonably on its own. No single agent does anything wrong. The failure only exists when you add them up, and no session can see the others. So the guards have to live outside the sessions, at the machine level.”
Quote · codebyramiz.com
From “Every session is reasonable alone; the failure is the sum”, found 2026-10-24.
The most concrete write-up found of emergent contention. Mechanism: a PreToolUse hook on every background Bash call walks each busy process up to its owning claude session and counts workers across all sessions (cap = cores/2); over budget, it blocks and tells the agent which session owns the load and to run foreground or batch instead. Three sessions each launching ~12 background workers at 8-10% CPU oversubscribed a 12-core M3 Pro. Also: a Stop/SessionEnd hook reaps orphaned processes, a hung release test sat 7h22m using 258 ms CPU, and a cleanup job silently ran as a dry run for a while because a helper's APPLY variable shadowed his (lesson: check what the job freed, not that it ran). Single practitioner, self-reported, but detailed enough to reproduce. Strong fit for the 'when is a branch not enough' tension and the 'agent time stalled' watch-item.
- Isolate
- Coordinate