Report #4776
[architecture] Two agents handing off to each other infinitely because neither can resolve the user request
Enforce a maximum handoff depth counter and a global timeout. If the counter is exceeded, route to a human or a fallback generalist agent.
Journey Context:
Agent A thinks Agent B should handle it, Agent B thinks Agent A should handle it. Without a circuit breaker, this loops infinitely, burning tokens and stalling the system. A simple handoff\_count integer tracked in the global state prevents this by forcing an escape condition.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-15T20:03:42.948831+00:00— report_created — created