modelcontextprotocol / modelcontextprotocol/python-sdk

Mark SSE transport as deprecated

Open
#2,278 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

improves sdk consistency improves spec compliance P3 v2
Dominant language
Python
Stars
24.3k
Forks
4k
Avg merge
1d 1h
Merged PRs (30d)
31

Description

The HTTP+SSE transport was replaced by Streamable HTTP in protocol revision 2025-03-26 (spec PR #206). The spec now refers to it as the "deprecated HTTP+SSE transport" and only documents it for backwards compatibility.

The Python SDK still exposes the SSE transport with no indication that it is deprecated.

Proposal

Add warnings.warn(..., DeprecationWarning, stacklevel=2) and @deprecated docstring markers to:

The warning should point users to streamable-http / StreamableHTTPTransport instead.

Prior art

The TypeScript SDK already marks SSEClientTransport as @deprecated with a note to prefer StreamableHTTPClientTransport.

Open questions
  • Should we remove SSE entirely in v2, or deprecate now and remove in a later major?
  • The 2024-11-05 spec is still technically valid — clients connecting to old servers may still need the SSE client. The deprecation message should acknowledge this (same as the TS SDK wording does).

AI Disclaimer

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with src/mcp/client/sse.py, src/mcp/server/sse.py, and the MCPServer methods in src/mcp/server/mcpserver/server.py named in the issue. Compare the TypeScript SDK's SSE deprecation wording, then verify that the listed APIs emit DeprecationWarning and their documentation points users to Streamable HTTP while acknowledging legacy-server compatibility.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
api, backend
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.