Mark SSE transport as deprecated

オープン
#2,278 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
68/100
issue の種類
機能追加
明瞭さ
明確に書かれている
活発さ
静か
技術スタック
python
領域
api, backend

調査の方向性

src/mcp/client/sse.py、src/mcp/server/sse.py、および src/mcp/server/mcpserver/server.py にある issue で指定された MCPServer メソッドから始めます。TypeScript SDK における SSE の非推奨化の文言と比較し、一覧にある API が DeprecationWarning を発行すること、また、それらのドキュメントがレガシーサーバーとの互換性を認めつつ、ユーザーに Streamable HTTP を案内していることを確認します。

索引モデルが issue の本文から書いたものです。

説明

improves sdk consistency improves spec compliance P3 v2

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

主要言語
Python
スター
24.3k
フォーク
4k
平均マージ
1日 19分
マージ済み PR(30日)
29

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

modelcontextprotocol/python-sdk のほかの issue

modelcontextprotocol/python-sdk の issue をすべて見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。