Subagents (Agent tool) cannot reach the LSP tool, contradicting documented MCP/tool inheritance
Description
The LSP tool (provided via the official LSP plugins, e.g. pyright-lsp@claude-plugins-official, rust-analyzer-lsp@claude-plugins-official, clangd-lsp@claude-plugins-official) is available and fully functional in the main conversation thread, but is completely unreachable from any subagent spawned via the Agent tool — built-in or custom, regardless of tools/disallowedTools configuration.
This contradicts the sub-agents documentation, which states:
Subagents inherit the internal tools and MCP tools available in the main conversation by default.
Repro
- Enable an LSP plugin (e.g.
pyright-lsp) insettings.jsonenabledPlugins, in a project with a supported language file. - In the main thread, confirm the tool is reachable:
```
ToolSearch({query: "select:LSP", max_results: 5})
LSP
→ returns the full function schema, and calling it (e.g. operation: "documentSymbol"`) works correctly.
- Spawn a plain, unmodified subagent via the
Agenttool (e.g.subagent_type: "general-purpose", no custom.claude/agents/*.mdoverride, notools/disallowedToolsrestriction) and have it run the identical call:
```
ToolSearch({query: "select:LSP", max_results: 5})
"No matching deferred tools found"`.
→ returns
Also reproduced with a custom subagent definition at .claude/agents/Explore.md (overriding the built-in Explore agent by name) using a disallowedTools denylist that does not mention LSP — same result, LSP is absent from that subagent's ToolSearch results.
Expected
Per the documented default, a subagent with no explicit tool restriction on LSP should be able to find and call it via ToolSearch, the same as the main thread.
Actual
LSP is never present in a subagent's deferred-tool registry, in any subagent context tested (built-in general-purpose, built-in Explore override, no restriction present in tools/disallowedTools).
Impact
This blocks any workflow that wants subagents (e.g. a read-only "Explore"/code-search subagent) to prefer LSP-based code navigation (documentSymbol, hover, goToDefinition, etc.) over grep/text search — the tool is architecturally unavailable to them, so prompt-level instructions to "try LSP first" cannot succeed no matter how the subagent is configured.
Environment
- Platform: Linux
- LSP plugins:
pyright-lsp@claude-plugins-official,rust-analyzer-lsp@claude-plugins-official,clangd-lsp@claude-plugins-official(all enabled insettings.json) - Reproduced via both the top-level
Agenttool withsubagent_type: "general-purpose"(default config, no overrides) and a custom.claude/agents/Explore.mdoverride
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗