Skip to content

fix: bump SDK to 1.26.0, fix tools_call scenario#134

Merged
pcarleton merged 3 commits intomainfrom
paulc/bump-sdk-1.26.0
Feb 5, 2026
Merged

fix: bump SDK to 1.26.0, fix tools_call scenario#134
pcarleton merged 3 commits intomainfrom
paulc/bump-sdk-1.26.0

Conversation

@pcarleton
Copy link
Member

@pcarleton pcarleton commented Feb 5, 2026

SDK 1.26.0 made Protocol.connect() throw if already connected to a transport. The tools_call scenario was calling server.connect(transport) on every request with the same Server instance, which now throws.

Fixed by adding proper protocol management: each initialize request creates a new Server + Transport pair.

SDK 1.26.0 made Protocol.connect() throw if already connected to a
transport. The tools_call scenario was calling server.connect(transport)
on every request with the same Server instance, which now throws.

Fixed by adding proper session management: each initialize request
creates a new Server + Transport pair, and subsequent requests are
routed to the correct transport via the mcp-session-id header.
@pkg-pr-new
Copy link

pkg-pr-new bot commented Feb 5, 2026

Open in StackBlitz

npx https://pkg.pr.new/modelcontextprotocol/conformance/@modelcontextprotocol/conformance@134

commit: 2f87479

The else branch was returning 400 for both missing-session and
invalid/stale-session cases. The MCP spec requires 404 for invalid
session IDs and 400 only for non-initialization requests without
any session ID.
Instead of adding session management, simply create a new Server
instance per request. This preserves the original stateless design
while fixing the SDK 1.26.0 Protocol.connect() restriction.
@pcarleton pcarleton changed the title fix: bump SDK to 1.26.0, add session management to tools_call scenario fix: bump SDK to 1.26.0, fix tools_call scenario Feb 5, 2026
@pcarleton pcarleton enabled auto-merge (squash) February 5, 2026 15:30
@pcarleton pcarleton merged commit 22196ca into main Feb 5, 2026
8 checks passed
@pcarleton pcarleton deleted the paulc/bump-sdk-1.26.0 branch February 5, 2026 15:43
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