--bare mode: --channels server:X cannot resolve servers provided via --mcp-config
Summary
When using --bare mode with --mcp-config to provide an MCP server, --channels server:X cannot resolve the server because --bare skips loading user config (~/.claude.json) where the server would normally be registered.
Reproduction
claude --bare \
--dangerously-skip-permissions \
--dangerously-load-development-channels server:myserver \
--channels server:myserver \
--mcp-config '{"mcpServers":{"myserver":{"command":"myserver","args":["serve"]}}}' \
-p "call my_tool"
The MCP server loads correctly — tools are available and callable. But --channels server:myserver does not activate the channel, so notifications/claude/channel events from the MCP server are not surfaced as <channel> tags in the conversation.
Expected behavior
Servers provided via --mcp-config should be resolvable by --channels server:X. The server is already loaded and running — the channel flag just needs to find it by name.
Actual behavior
The MCP server's tools work (confirmed via E2E tests), but channel notifications are silently dropped. The agent never sees <channel> tags from the server.
Context
This blocks automated E2E testing of MCP servers that use channel notifications (like the Telegram plugin pattern). In --bare mode there's no way to register a server as a channel — --mcp-config adds the server but --channels can't find it, and --bare skips user config where it would normally be registered.
Workaround
None for --bare mode. In normal mode, claude mcp add + --channels server:X works because the server is in ~/.claude.json.
Environment
- Claude Code: latest
- OS: Windows 11, Ubuntu 24.04 (CI)
- Tested with custom Go MCP server using
claude/channelexperimental capability
This issue has 5 comments on GitHub. Read the full discussion on GitHub ↗