Repository navigation
Conversation
The server pinned ProtocolVersion to 2025-11-25, which refuses clients on the 2026-07-28 protocol and overrides the version older clients ask for. Leaving it null makes the server dual-era: initialize clients get the version they ask for and 2026-07-28 clients are served through server/discover. A new http test pins the three behaviours. The handshake tests now send 2025-11-25, which is what clients send today. Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Mpdreamz
added a commit
that referenced
this pull request
Nov 16, 2026
* Format project files the way curb 0.14 does Curb 0.14 formats XML with the editorconfig indent. The 16 project files and the solution file change in whitespace only. Co-Authored-By: Claude Sonnet 5.5 <[email protected]> * Move the nullean libraries and tools to the latest releases Snapshots 0.11, Argh and Make.Fs 0.29, Proc 0.22, Cdp 0.11, Mermaider 0.17, curb 0.14 and the release-notes tool. The 0.11 snapshot engine keeps whitespace inside pre, so those verified files now show the real markup, and the MCP event stream snapshot lists the JSON of each event. ScopedFileSystem stays on 0.6.0, Snapshots on 0.11.0 and Pagefind.Net on 0.5.0. The newer releases need System.IO.Abstractions 23, whose Testably interface adds IFile.CreateHardLink, and ScopedFileSystem 0.7.1 does not implement it. Docker targets now fail up front when docker is missing (needsTool). Co-Authored-By: Claude Sonnet 5.5 <[email protected]> * Match the MCP handshake journey to the SSE rendering of the new Nullean.Snapshots The snapshot library now pretty-prints event-stream bodies itself, so the SSE scrubber is a no-op and the prose mask no longer matched. Mask the prose in the new format and regenerate the verified file. Co-Authored-By: Claude Sonnet 5.5 <[email protected]> * Bring the other dependencies and dotnet tools up to date AWSSDK 4.1, Elastic.Clients.Elasticsearch 9.5, Elastic.Transport 1.1, Elastic.Ingest 0.56, HtmlSanitizer 11, AngleSharp 1.10, Markdig 1.6, OpenTelemetry 1.21, TUnit 1.83, WireMock 2, Spectre.Console 0.57, Slugify 5, MinVer 8, husky and the other packages that had a newer release. Slugify 5 no longer takes a null, so Slugify() passes an empty string for one. Four stay behind. RazorSlices 0.12 writes empty attributes, which changes the HTML of 77 snapshots. ModelContextProtocol 2 changes the tool annotations and input schemas that the MCP server returns. Elastic.OpenTelemetry 1.7 ships a ReadOnlyMemoryStream that collides with the one in the net11 BCL. Elastic.Transport 8 breaks the client code that uses JsonResponse. Co-Authored-By: Claude Sonnet 5.5 <[email protected]> * Test that Slugify returns an empty string for null input Co-Authored-By: Claude Sonnet 5.5 <[email protected]> * Keep Slugify.Core on 4.0.1 Slugify 5 rejects a null argument and Slugify() takes a nullable string. A null-coalescing workaround would hide a behaviour change, so the package stays until the repo has its own slug method. Co-Authored-By: Claude Sonnet 5.5 <[email protected]> * Take Elastic.OpenTelemetry 1.7 and stop using ReadOnlyMemoryStream in the API tests Elastic.OpenTelemetry 1.7 ships a public System.IO.ReadOnlyMemoryStream in its netstandard2.1 asset. The net11 runtime has a type of that name too, so the API test projects, which reference the package, fail with CS0433. The tests read a byte array, so a read-only MemoryStream does the same job. Co-Authored-By: Claude Sonnet 5.5 <[email protected]> * Take RazorSlices 0.12 and leave empty attributes out of the HTML RazorSlices 0.12 writes an attribute bound to an empty string as name="", where 0.11 left it out. The tab and applies-switch radios bound checked to "checked" or "", so every radio would have been checked. The templates now bind null instead, through NullIfEmpty and JoinOrNull, so the HTML stays the same and no snapshot changes. Co-Authored-By: Claude Sonnet 5.5 <[email protected]> * Make Slugify() return an empty string for null Slugify.Core 4.0.1 throws a NullReferenceException for null although Slugify() takes a string?. The guard lives in our method, so it holds for any version of the package or a replacement (see the issue about our own slug method). Co-Authored-By: Claude Sonnet 5.5 <[email protected]> * Take ModelContextProtocol 2.4 The six tools, their descriptions, input schemas and annotations are the same. tools/list now returns them in a different order and no longer advertises execution.taskSupport. Both handshake snapshots follow. Co-Authored-By: Claude Sonnet 5.5 <[email protected]> * Offer every MCP protocol version instead of pinning one (#4837) The server pinned ProtocolVersion to 2025-11-25, which refuses clients on the 2026-07-28 protocol and overrides the version older clients ask for. Leaving it null makes the server dual-era: initialize clients get the version they ask for and 2026-07-28 clients are served through server/discover. A new http test pins the three behaviours. The handshake tests now send 2025-11-25, which is what clients send today. Co-authored-by: Claude Sonnet 5.5 <[email protected]> * Cover a tools/call over the 2026-07-28 protocol The protocol versions test sent server/discover and tools/list on 2026-07-28 but no call that runs a tool. A get_document_by_url call with an empty URL now goes through the per-request path and snapshots the tool result. Co-Authored-By: Claude Sonnet 5.5 <[email protected]> * Stub the document gateway in the MCP handshake tests The tools/call request in the protocol versions test still reached Elasticsearch: the gateway searches even for an empty URL. The test host now replaces IDocumentGateway with one that echoes the URL, so the test does not depend on a cluster and its snapshot shows that the argument arrived. Co-Authored-By: Claude Sonnet 5.5 <[email protected]> * Run the MCP handshake cases one at a time With two .http files the cases run in parallel, and each sets and restores the process-wide MCP_SERVER_PROFILE, so one could restore it while the other host starts. They now share a NotInParallel key. Co-Authored-By: Claude Sonnet 5.5 <[email protected]> --------- Co-authored-by: Claude Sonnet 5.5 <[email protected]> Co-authored-by: Mpdreamz <[email protected]>
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.
Removes the
ProtocolVersionpin from the remote MCP server, so it serves clients on the 2026-07-28 protocol as well as the ones that still useinitialize.Affects: MCP
Prompt summary: After moving to ModelContextProtocol 2.4, decide whether to lift the pin to
2025-11-25, check what current guidance says, and prepare the change with the reasons.Why
Program.cspinsProtocolVersionto2025-11-25. With the 2.x SDK the pin has two costs:400with code-32022andsupported: ["2025-11-25"]. SDK clients fall back toinitialize. Other clients may not.2024-11-05gets2025-11-25back.Pinning to
2026-07-28instead is not an option. The SDK documents that it makes the server reject everyinitializehandshake, and nearly every client still usesinitialize. I did not run that pin on our server.The spec describes the alternative. A server that supports both eras is called dual-era, and the versioning page of the 2026-07-28 revision says:
initializeand serves the client by the negotiated legacy revision.server/discover.UnsupportedProtocolVersionErrorthat lists the versions it supports. That is the-32022response above.The C# SDK versioning page says a v2 server keeps accepting
initializefrom down-level clients. It does not recommend a value forProtocolVersion. The SDK's own reference for the property says thatnullsupports all versions.What
The server
ProtocolVersionis left null, with a comment that says why. That is the dual-era setup of the spec. Stateless HTTP stays as it is.What clients see
Measured on the test host:
initializeasking for2025-11-252025-11-25initializeasking for2024-11-052025-11-252024-11-05server/discoverandtools/liston 2026-07-28400,-32022200On 2026-07-28 the request needs the
Mcp-Protocol-VersionandMcp-Methodheaders, and theserver/discoverresult has atoolscapability and nologgingcapability. The results carry no caching hints. The tools and their schemas are the same as for aninitializeclient.Tests
mcp-protocol-versions.httppins the three behaviours above. The two handshake files, inMcp.Remote.Testsand the journeys project, now ask for2025-11-25, which is what clients send today, so their snapshots do not change. They asked for2024-11-05before only to guard the pin. I put the pin back once and the new test failed.Verify
Risk: an older client now negotiates the version it asks for, not
2025-11-25. I did not check how a real old client behaves without 2025-11-25 features. I did not run atools/callover 2026-07-28 either, because it needs the search backend. Try Claude Desktop and VS Code against the preview before merging.Stack: 4 of 4, on top of #4836.