Skip to content

Commit ee9b104

Browse files
committed
Remove Tasks (SEP-1686) from the SDK
Tasks have been removed from the MCP specification and will return as a separate extension in a future release. This removes all task-related code, types, examples, tests, and documentation from the SDK. Removed: - All Task* types, capability fields, Tool.execution, and union members from mcp.types - mcp.{client,server,shared}.experimental packages - mcp.server.lowlevel.experimental and mcp.shared.response_router - experimental properties on ClientSession, ServerSession, Server, and the experimental field on ServerRequestContext - ServerSession._build_*_request helpers, send_message, and the tasks capability check (task-only consumers) - BaseSession.add_response_router and the router-dispatch loop in _handle_response (the method extraction itself is kept) - tests/experimental/ and the tasks:* entries in tests/interaction/_requirements.py - examples/{clients,servers}/simple-task* and their uv.lock workspace members - docs/experimental/ and the mkdocs nav section Kept: - CancelledNotificationParams.request_id stays optional to match the draft schema; only the docstring was updated - server/validation.py (non-task sampling-validation refactor) - _handle_response extraction in BaseSession Added a test for ServerSession.check_client_capability since the experimental task tests were its only coverage.
1 parent 2472563 commit ee9b104

81 files changed

Lines changed: 60 additions & 13155 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

README.v2.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2489,7 +2489,6 @@ MCP servers declare capabilities during initialization:
24892489
## Documentation
24902490

24912491
- [API Reference](https://modelcontextprotocol.github.io/python-sdk/api/)
2492-
- [Experimental Features (Tasks)](https://modelcontextprotocol.github.io/python-sdk/experimental/tasks/)
24932492
- [Model Context Protocol documentation](https://modelcontextprotocol.io)
24942493
- [Model Context Protocol specification](https://modelcontextprotocol.io/specification/latest)
24952494
- [Officially supported servers](https://github.com/modelcontextprotocol/servers)

docs/experimental/index.md

Lines changed: 0 additions & 42 deletions
This file was deleted.

0 commit comments

Comments
 (0)