The wakeup channel caused duplicate message delivery: inbox delivery and idle state transitions both signaled an immediate wakeup with bypassIdleCheck=true, prompting bots before they were ready. Replace with a simple 5-second ticker. The idle threshold is always applied, eliminating the race condition. Worst-case delivery latency is 10 seconds (one tick to drain outboxes, next tick to prompt). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| manager.go | ||