Claim MCP 2026-07-28 (#115) - #130
Merged
Merged
Conversation
Everything the revision asks of a server is implemented: stateless dispatch, server/discover, resultType, cacheable tools/list, the error-code policy, the transport metadata headers and status codes, subscriptions/listen, tasks. So the revision joins SupportedProtocolVersions and the server says so when asked. MRTR confirmed inapplicable rather than assumed. Every server obligation in SEP-2322 is conditional on choosing to return an InputRequiredResult - "servers MAY respond" - and this server initiates no sampling, elicitation or roots requests, so it never returns one. Its results are all resultType "complete", which is conformant. Best-effort is gone with the thing that needed it. While 2026-07-28 was half-built, refusing a request that declared it would have put its own features out of reach; now there is one rule, and it is the negotiation working as designed: a revision is either implemented and served properly, or the client is told so with the list it can choose from. 2025-11-25 is the interesting case - a real revision we have not reviewed, so it is refused, because claiming a revision we have not read is the exact dishonesty the list exists to prevent. Two things this exposed, both fixed here: - The handshake-negotiated revision now shapes later requests that name none. A client that agreed 2026-07-28 at initialize and then got 2025-06-18-shaped results back would have been misled by us, not by the protocol. - ProtocolVersion and "the newest revision" had been the same constant and are no longer the same idea. LatestProtocolVersion is what we implement; ProtocolVersion is what the legacy handshake answers when the client names nothing - deliberately NOT the newest, since using initialize at all predates the revision that removed it. A version refusal is now 400 over HTTP whatever the request declared: only a request that named a version can be refused for it, so its client is version-aware by definition and the status is what tells it to read the list. Verified on the built exe: discover reports all four versions newest-first, a 2026-07-28 tools/list comes back complete with the cache hints, 2025-11-25 is refused with -32022 and the list, and a request with no _meta still gets the old shape untouched.
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.
Closes #115. The closing move of the epic.
Everything the revision asks of a server is implemented — stateless dispatch,
server/discover,resultType, cacheabletools/list, the error-code policy, the transport metadata headers and status codes,subscriptions/listen, tasks. So2026-07-28joinsSupportedProtocolVersions, and the server says so when asked.MRTR: confirmed, not assumed
I read SEP-2322 rather than carry the earlier assumption. Every server obligation in it is conditional on choosing to return an
InputRequiredResult— "Servers MAY respond to any supported client request with anInputRequiredResult" — and this server initiates no sampling, elicitation or roots requests, so it never returns one. All of its results areresultType: "complete", which is conformant. The one MUST that could bind us ("Servers MUST send server-to-client requests using the MRTR pattern") is vacuous for a server that sends none.Best-effort is gone, with the thing that needed it
While 2026-07-28 was half-built, refusing a request that declared it would have put its own features out of reach of the only clients asking for them. That justification is spent. One rule now: a revision is either implemented and served properly, or the client is told so with the list it can choose from.
2025-11-25is the interesting case — a real revision we have not reviewed, so it is refused. Claiming a revision we haven't read is the exact dishonesty the list exists to prevent, and there's a test holding it off the list.Two things this exposed
initializeand then got 2025-06-18-shaped results back would have been misled by us, not by the protocol. Adding the revision to the list is what made that reachable.ProtocolVersionand "the newest revision" were the same constant and are no longer the same idea.LatestProtocolVersionis what we implement;ProtocolVersionis what the legacy handshake answers when the client names nothing — deliberately not the newest, because usinginitializeat all predates the revision that removed it.Also: a version refusal is now
400over HTTP whatever the request declared. Only a request that named a version can be refused for it, so its client is version-aware by definition, and the status is what tells it to read the list.Verification
ErrorCodeTestsnow walks served-vs-refused across five declared versions.server/discoverreports all four versions newest-first; a 2026-07-28tools/listreturnsresultType: "complete"withttlMs/cacheScope;2025-11-25is refused with-32022and the supported list; a request with no_metastill gets the old shape untouched — which is the compatibility promise this whole epic was built on.README and the startup log updated: the server now reports the full supported set rather than a single revision.