Commit graph python-sdk/tests/conftest.py
Author SHA1 Message Date
Marcelo Trylesinski
6affe5c0d3
Detect event-loop blocking in tests (#3510)
Some checks failed
Conformance Tests / server-conformance (push) Has been cancelled
Conformance Tests / client-conformance (push) Has been cancelled
Deploy Docs / deploy-docs (push) Has been cancelled
CI / checks (push) Has been cancelled
GitHub Actions Security Analysis / zizmor (push) Has been cancelled
CI / all-green (push) Has been cancelled
2026-09-16 12:12:27 +02:00
Max
867bba6263
Share one event loop per test module to stop Windows socketpair churn (#3070) 2026-07-07 13:19:04 +01:00
Max
5d826490b6
[v2] Dispatcher/ServerRunner receive-path swap — replaces BaseSession (#2710) 2026-06-09 12:58:47 +01:00
David Soria Parra
f10665db4c
tests: cleanup 2025-02-05 11:02:51 +00:00
David Soria Parra
680afeeed6
fix pydantic version 2024-12-21 01:04:30 +00:00
David Soria Parra
557e90d2e7
Integrate FastMCP
This commit integrates FastMCP, a high-level MCP server implementation originally written by Jeremiah Lowin,
into the official MCP SDK. It also updates dependencies and adds new dev dependencies.
It moves the existing SDK into a .lowlevel .
2024-12-21 00:41:38 +00:00
David Soria Parra
f5d82bd229
Remove helper types
The helper types in mcp.server.types got really confusioning during
implementation as they overlapped with mcp.types. I now believe it
is better if we stay more low level to the spec types.

To do this, we now only use mcp.types everywhere. We renamed mcp.server.types
to mcp.server.models and removed it to the absolute minimum.
2024-11-11 20:05:51 +00:00
David Soria Parra
ed87ae9f06
rename mcp_python to mcp 2024-11-11 12:40:32 +00:00
Justin Spahr-Summers
c7d8f11e0c
Formatting 2024-11-06 12:35:32 +00:00
Nick Merrill
60e9c7a0d7
Add in-memory transport (#25)
## Goal

Support running an MCP server in the same process as the client, while preserving MCP abstractions.

## Details

1. **(core change)** Adds a new `memory` transport module that enables in-process client-server communication.
This includes:
   - `create_client_server_memory_streams()` to create bidirectional memory streams
   - `create_connected_server_and_client_session()` to establish an in-process client-server connection

3. (minor) Enhances error handling and timeout support:
   - Adds configurable read timeouts to sessions via `read_timeout_seconds` parameter
   - Improves exception handling in the server with a new `raise_exceptions` flag to control whether errors are returned to clients or raised directly
   - Ensures proper cleanup of request context tokens in error cases

4. (minor) Makes server improvements:
   - Adds built-in ping handler support
2024-11-05 15:42:41 -08:00