Commit 47e9ca3
fix: enable tool activation for Claude clients in mcp-add
The mcp-add command was incorrectly skipping tool activation for Claude
clients based on the assumption that "Claude clients auto-refresh their
tool list". This assumption is incorrect.
When mcp-add is called with activate=true, tools were added to
g.toolRegistrations (accessible via mcp-exec) but NOT to g.mcpServer
(required for native MCP tool calls). This caused:
- mcp-add chromedev → success (26 tools registered)
- mcp-exec chromedev:list_pages → works (uses toolRegistrations)
- native call to chromedev:list_pages → "unknown tool" error
The fix removes the Claude client exclusion, allowing updateServerCapabilities()
to call g.mcpServer.AddTool() for all clients.
Related to docker#278 (tool-name-prefix dispatch fix)
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>1 parent 94b4ea8 commit 47e9ca3
1 file changed
+3
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
229 | 229 | | |
230 | 230 | | |
231 | 231 | | |
232 | | - | |
233 | | - | |
234 | | - | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
235 | 235 | | |
236 | 236 | | |
237 | 237 | | |
| |||
0 commit comments