Repository navigation
fix(mcp): work with protocol 2026-07-28 clients (2.3.2) - #10
Merged
Merged
Conversation
Claude Code 2.1.296 talks to MCP servers with protocol 2026-07-28: it
sends server/discover instead of initialize, with the version in _meta.
Laci offered that version, but its tools/list result lacked ttlMs and
cacheScope, which 2026-07-28 requires on list results, so Claude Code
rejected Laci's tools ("tools fetch failed").
rmcp 3.5.0 added the hints only to results built by its handler macros,
and Laci builds its tool list itself. rmcp 3.5.1 fills in missing hints
for every 2026-07-28 peer (ttlMs 0, cacheScope private). Sessions that
start with initialize keep the old shape.
The MCP smoke check now also speaks 2026-07-28: server/discover must
offer it, and tools/list with the same _meta must return the 15 tools
with both hints.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
Claude Code 2.1.296 connects to MCP servers with protocol 2026-07-28. It skips
initializeand sendsserver/discoverwith_meta["io.modelcontextprotocol/protocolVersion"] = "2026-07-28". Laci 2.3.1 lists that version insupportedVersions, but itstools/listresult then has nottlMsorcacheScope, which 2026-07-28 requires on list results (SEP-2549). Claude Code rejects the list, so Laci's tools are missing:Cause
rmcp 3.5.0 added the hints only to results built by its
#[tool_handler]and#[prompt_handler]macros. Laci implementslist_toolsitself (ListToolsResult::with_all_items), so the fields stayed empty and were left out of the JSON.What changes
Cargo.lockonly. 3.5.1 fills in missing hints for every 2026-07-28 peer (rust-sdk#1308):ttlMs: 0andcacheScope: "private", so clients never cache the list. Sessions that start withinitializekeep the old shape.mcp.rsis unchanged.laci mcpis spoken to with 2026-07-28.server/discovermust list2026-07-28, andtools/listwith the same_metamust return the 15 tools with a numericttlMsand acacheScopeofpublicorprivate. 28 → 30 checks. Starting and stopping the server moved intostart()andstop(); the existing checks are unchanged.Cargo.toml,Cargo.lock,package.json,ui/package.jsonandtauri.conf.json, the changelog entry, and the README status line, which still said 2.1.0.Checks
cargo fmt --all -- --check, strict Clippy andcargo test --workspace --features custom-protocol: 180 passed, 1 ignored.node scripts/ui-state-smoke.mjs.node scripts/mcp-smoke.mjs target/debug/laci:MCP smoke passed: 15 tools, 30 checks, …. Against 2.3.1 the new check fails withtools/list must carry ttlMs for 2026-07-28 clients.tools/listkeys for a 2026-07-28 request: 2.3.1["resultType","tools"], this branch["resultType","ttlMs","cacheScope","tools"](ttlMs: 0,cacheScope: "private"). A session started withinitializeat 2025-11-25 still gets["tools"].claude mcp add --scope local <name> -e LACI_HOME=<empty dir> -- <binary> mcp, thenclaude mcp get <name>:~/.local/bin/laci):Status: ! Connected · tools fetch failed, with the issue abovetarget/debug/laci):Status: ✔ ConnectedAfter merge
v2.3.2is tagged and the release is published.