[BUG] Channel plugin silently fails when --channels flag is omitted
Summary
When a channel plugin (e.g., Discord) is installed but the session is started without --channels, inbound messages are silently dropped with no error or warning. The bot appears to work (typing indicator shows briefly) but notifications never reach the session.
Steps to Reproduce
- Install the Discord plugin:
/plugin install→discord@claude-plugins-official - Configure the bot token:
/discord:configure <token> - Complete pairing and set allowlist policy
- Start a new session without
--channels:
``bash``
claude
/reload-pluginsconfirms:1 plugin MCP server— looks healthy- Send a DM to the bot from Discord
Expected Behavior
Either:
- The message arrives in the session, OR
- A clear warning/error explains that
--channelsis required for inbound notifications
Actual Behavior
- The bot receives the DM (confirmed via
psandlsof— Gateway TCP connection active) - Discord shows "Bot is typing..." for ~2 seconds, then it disappears
- No error in stderr, no warning in the session, no notification
- The message is silently lost
- MCP tools (
reply,fetch_messages) work fine — only inbound notifications are broken
Why This Is Confusing
The debugging surface is completely clean:
/reload-pluginsreports1 plugin MCP server✅- Bot process is running (
bun server.ts) ✅ - Discord Gateway is connected (TCP ESTABLISHED to Discord CDN) ✅
- MCP stdio pipe is connected (Unix socket to Claude Code PID) ✅
sendTyping()succeeds (typing indicator appears) ✅mcp.notification()is called without throwing ✅- Zero errors anywhere — the failure is completely silent
The root cause is that mcp.notification() sends the notification over stdio, but Claude Code doesn't process it as a channel notification without --channels. There is no feedback loop to tell the plugin (or the user) that notifications are being ignored.
Proposed Fix
When a plugin MCP server sends notifications/claude/channel but no channels are active (i.e., --channels was not passed), Claude Code should:
- Log a warning to the session: _"Channel notification received from 'discord' but no channels are active. Start with
--channels plugin:discord@claude-plugins-officialto enable."_ - Optionally, surface this in
/reload-pluginsoutput: _"Note: 'discord' is a channel plugin. Start with--channelsto receive inbound messages."_
Related Issues
- #37139 — notifications dropped when session is idle (different: that's about idle sessions; this is about missing
--channelsflag entirely) - #36986 — liveness indicator for channels (complementary)
Environment
- Claude Code v2.1.81
- macOS
- Plugin:
discord@claude-plugins-officialv0.0.1
This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗