Channel notifications miss turn cycle on idle Claude Code sessions
Context
I've been building khimaira-chat, a multi-agent orchestration layer for Claude Code that uses the claude/channel research-preview capability extensively. We push events to peer Claude Code sessions via SSE → notifications/claude/channel.
Symptom
When a Claude Code session is idle (no active prompt, no in-flight tool call) and an external SSE event arrives that emits a notifications/claude/channel JSON-RPC notification, the receiving session sometimes does not start a new turn — the channel block isn't surfaced until the user types something to trigger the next user-prompt cycle.
Active sessions (any in-flight work) appear to surface channel blocks reliably. Idle sessions appear to receive the notification at the protocol level but not always trigger the turn cycle.
Reproduction
- Two Claude Code windows, each with the
khimaira-chatMCP server registered - Window A:
mcp__khimaira-chat__chat_send(chat_id, body)to a chat both windows are members of - Window B: idle (no prompt typed, last response received N minutes ago)
- Expected: Window B starts a new turn surfacing the channel block
- Observed (intermittent): Window B doesn't refresh until user types in it
Why this matters
True auto-delivery is the load-bearing affordance for multi-agent orchestration — without it, agents have to poll, which defeats the channels primitive's design.
Workarounds we've shipped
- Proactive SSE subscriber in the MCP subprocess that opens the SSE stream at boot, independent of tool calls (commit
0b02304) - SSE keepalive + client read timeout to survive laptop suspend/resume (commit
79a5611) - Exponential SSE backoff on reconnect (commit
ca642b5)
These help in many cases but the underlying idle-turn-cycle gap still occasionally surfaces.
Happy to provide
- More detailed reproduction recipes from our dogfood rounds
- Daemon-side SSE traces correlated with Claude Code's response timing
- Specific session IDs / timestamps if telemetry exists
Filed as one of several pieces of feedback on the claude/channel primitive — happy to chat about the broader multi-agent orchestration usage if useful.
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗