Skip to content

fix: accept metadata on legacy conformance initialize - #20

Merged
lucarlig merged 1 commit into
mainfrom
user/luca/fix-conformance-initialize-meta
Sep 21, 2026
Merged

lucarlig merged 1 commit into
mainfrom
user/luca/fix-conformance-initialize-meta

Conversation

@lucarlig

Copy link
Copy Markdown
Contributor

Summary

  • classify session-era initialize requests from params.protocolVersion before the harness's modern-era routing
  • accept optional RequestParams._meta, including the empty metadata object emitted by MCP Python SDK 2.x
  • record the fixture correction in the changelog

This is the harness-side fix for the failure seen in IBM/mcp-context-forge#6868. The same root fix is proposed upstream in modelcontextprotocol/conformance#507; keeping it in the pinned fixture patch unblocks ContextForge without waiting for a new upstream conformance release.

Validation

  • built docker/mcp-conformance-server.Dockerfile from the pinned alpha.11 revision
  • started the image in legacy mode and received HTTP 200 plus Mcp-Session-Id for an initialize request containing _meta: {}
  • cargo test --locked (431 tests)
  • git diff --check

Treat session-era initialize requests as legacy based on params.protocolVersion even when optional request metadata is present. This prevents MCP Python SDK 2.x initialization from being rejected as modern traffic.

Signed-off-by: lucarlig <luca.carlig@ibm.com>
@lucarlig
lucarlig marked this pull request as ready for review September 18, 2026 17:48

@madhu-mohan-jaishankar madhu-mohan-jaishankar left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@lucarlig
lucarlig merged commit 118d2cb into main Sep 21, 2026
18 of 19 checks passed
@lucarlig
lucarlig deleted the user/luca/fix-conformance-initialize-meta branch September 21, 2026 10:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants