From 2eddc6e02504ce2ef198f091a71e256231182631 Mon Sep 17 00:00:00 2001 From: Aniket Wagh Date: Fri, 28 Aug 2026 01:01:57 +0530 Subject: [PATCH 1/4] feat(mcp): support mcp 2.x alongside 1.x MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `mcp>=1.28.1,<2.0.0` left chainlit as the only package in many dependency graphs holding the MCP SDK below 2.0, released 2026-07-28 and now at 2.1.1. Relax the cap to `<3.0.0` and migrate the streamable-http call site, the only part of the surface that actually changed: - `streamablehttp_client` (removed in 2.0.0) becomes `streamable_http_client`. The new name has existed since 1.24.0 — below the current floor — and its signature is identical across 1.28.1, 1.29.1 and 2.1.1, so one code path serves both major lines with no conditional imports or version sniffing. - It takes a ready-made `http_client=` instead of a factory, so the client is built here and entered into the connection's `AsyncExitStack`: the transport only closes a client it created itself. It uses `Timeout(30, read=300)`, matching what the removed wrapper passed the factory — the factory's bare 30s default would cut a long-lived GET stream at 30s. - `mcp>=2` dispatches with `httpx2` rather than `httpx`, and the two are not interchangeable at runtime, so the SSRF guard (`follow_redirects=False` plus the per-request destination hook) is built from whichever module the installed SDK uses, resolved from the SDK itself rather than from whatever happens to be importable. `sse_client` keeps `headers=` and `httpx_client_factory=` in 2.x, so that call site is unchanged. No dependency-floor changes are needed: chainlit's constraints are ranges, and pydantic, anyio and starlette resolve to the same versions under either MCP line. The lockfile stays on 1.29.1, so this unblocks 2.x without moving anyone onto it. Tests: the guards pinned to the removed symbol now assert `http_client` on `streamable_http_client`, the httpx-typed assertions follow the resolved module, and TestConnectMcpBindsDestination gains a streamable-http case proving the bound client reaches the transport — dropping `http_client=` fails it. Backend suite passes against both 1.29.1 and 2.1.1. Closes #3002 Co-Authored-By: Claude Opus 5 (1M context) --- backend/chainlit/mcp.py | 77 ++++++++++++++- backend/chainlit/server.py | 22 +++-- backend/pyproject.toml | 2 +- backend/tests/test_mcp.py | 185 ++++++++++++++++++++++++++++++++----- uv.lock | 2 +- 5 files changed, 250 insertions(+), 38 deletions(-) diff --git a/backend/chainlit/mcp.py b/backend/chainlit/mcp.py index 3f96f0d1a3..6b779eb115 100644 --- a/backend/chainlit/mcp.py +++ b/backend/chainlit/mcp.py @@ -1,3 +1,4 @@ +from types import ModuleType from typing import Callable, Dict, Literal, Optional, Union from urllib.parse import unquote, urlparse @@ -242,6 +243,35 @@ def check(url: str) -> None: _MCP_CONNECT_TIMEOUT_STDIO = 120.0 # npx -y can cold-download on first run _MCP_CONNECT_TIMEOUT_HTTP = 30.0 +# The SDK's own transport defaults, from +# ``mcp.shared._httpx_utils.create_mcp_http_client``: 30s for +# connect/write/pool and 300s for read, the long read budget being what keeps +# a long-lived SSE or streamable-http GET stream from being cut mid-stream. +# Mirrored rather than imported because they live in a private module. +_MCP_HTTP_TIMEOUT = 30.0 +_MCP_HTTP_SSE_READ_TIMEOUT = 300.0 + + +def _mcp_http_module() -> ModuleType: + """Return the HTTP library the installed MCP SDK dispatches with. + + ``mcp<2`` builds its clients from ``httpx``; ``mcp>=2`` moved to + ``httpx2``. Those are separate distributions with separate class + hierarchies, and a transport only accepts a client built from its own, so + the guarded client below has to come from whichever one the installed SDK + uses. + + Resolved from the SDK's own factory module rather than by importing + whichever library happens to be present: ``httpx2`` can be installed for + unrelated reasons while ``mcp`` is still on 1.x, and guessing wrong would + hand the transport a client it rejects. ``test_mcp.py`` pins this against + what ``create_mcp_http_client`` actually returns, so an SDK that changes + the binding fails loudly instead of silently degrading. + """ + from mcp.shared import _httpx_utils + + return getattr(_httpx_utils, "httpx2", None) or httpx + def make_mcp_http_client_factory( check_destination: Callable[[str], None], @@ -275,10 +305,19 @@ def make_mcp_http_client_factory( threaded through here) so this module stays free of asyncio primitives and stays synchronously testable. - Passed as ``httpx_client_factory=`` to ``sse_client`` and - ``streamablehttp_client``. That parameter is present unchanged across the - supported ``mcp>=1.11.0,<2.0.0`` range. + Passed as ``httpx_client_factory=`` to ``sse_client``, and used to build + the ``http_client=`` handed to ``streamable_http_client`` (see + ``make_mcp_streamable_http_client``). Both parameters are present + unchanged across the supported ``mcp>=1.28.1,<3.0.0`` range. + + The client is built from whichever HTTP library the installed SDK + dispatches with, not from ``httpx`` directly — ``mcp>=2`` uses ``httpx2``, + and the two are not interchangeable at runtime. The annotations below name + the ``httpx`` classes because that is the flavour chainlit itself depends + on; the ``httpx2`` equivalents are API-compatible for everything used + here. """ + http = _mcp_http_module() def factory( headers: Optional[Dict[str, str]] = None, @@ -293,12 +332,40 @@ async def _check_request(request: httpx.Request) -> None: on_blocked(exc) raise - return httpx.AsyncClient( + return http.AsyncClient( follow_redirects=False, - timeout=timeout if timeout is not None else httpx.Timeout(30.0), + timeout=timeout if timeout is not None else http.Timeout(30.0), headers=headers, auth=auth, event_hooks={"request": [_check_request]}, ) return factory + + +def make_mcp_streamable_http_client( + factory: McpHttpClientFactory, + headers: Optional[Dict[str, str]] = None, +) -> httpx.AsyncClient: + """Build the guarded client passed to ``streamable_http_client``. + + ``streamable_http_client`` takes a ready-made ``http_client=`` rather than + the factory the deprecated ``streamablehttp_client`` wrapper used, so the + timeout that wrapper used to supply has to be supplied here: it called the + factory with ``Timeout(30, read=300)``, and leaving the factory's own + 30-second default in place would cut a long-lived GET stream at 30s. + + Takes the factory already bound to this connection's destination grant + rather than re-deriving it, so the guard cannot drift from the one the SSE + path uses. + + The caller owns the returned client: ``streamable_http_client`` only closes + a client it created itself, so this one must be closed by whoever passes it + (``server.py`` enters it into the connection's ``AsyncExitStack``). + """ + http = _mcp_http_module() + + return factory( + headers=headers, + timeout=http.Timeout(_MCP_HTTP_TIMEOUT, read=_MCP_HTTP_SSE_READ_TIMEOUT), + ) diff --git a/backend/chainlit/server.py b/backend/chainlit/server.py index 68238cd254..f90322b12b 100644 --- a/backend/chainlit/server.py +++ b/backend/chainlit/server.py @@ -1433,7 +1433,7 @@ async def connect_mcp( get_default_environment, stdio_client, ) - from mcp.client.streamable_http import streamablehttp_client + from mcp.client.streamable_http import streamable_http_client from chainlit.config import SseMcpServer, StdioMcpServer, StreamableHttpMcpServer from chainlit.context import init_ws_context @@ -1449,6 +1449,7 @@ async def connect_mcp( _destination_in_allowlist, _destination_on_origin, make_mcp_http_client_factory, + make_mcp_streamable_http_client, validate_mcp_headers, validate_mcp_url, ) @@ -1676,14 +1677,21 @@ async def _mcp_session_runner() -> None: ) elif isinstance(mcp_connection, HttpMcpConnection): assert mcp_http_client_factory is not None - # NOTE: streamablehttp_client is deprecated from mcp 1.24.0 - # (renamed streamable_http_client, taking http_client= instead - # of a factory) and removed in 2.0.0 — update this on bump. + # streamable_http_client takes a ready-made client rather + # than a factory, and only closes one it created itself, so + # this one is ours to close. Entered before the transport so + # the exit stack unwinds it last — terminate_on_close sends a + # DELETE through it while the transport is shutting down. + http_client = await exit_stack.enter_async_context( + make_mcp_streamable_http_client( + mcp_http_client_factory, + headers=mcp_connection.headers, + ) + ) transport = await exit_stack.enter_async_context( - streamablehttp_client( + streamable_http_client( url=mcp_connection.url, - headers=mcp_connection.headers, - httpx_client_factory=mcp_http_client_factory, + http_client=http_client, ) ) else: diff --git a/backend/pyproject.toml b/backend/pyproject.toml index c10a3c2686..10b1cf80f4 100644 --- a/backend/pyproject.toml +++ b/backend/pyproject.toml @@ -42,7 +42,7 @@ dependencies = [ "aiofiles>=23.1.0", "syncer>=2.0.3,<3.0.0", "asyncer>=0.0.8,<0.1.0", - "mcp>=1.28.1,<2.0.0", + "mcp>=1.28.1,<3.0.0", "nest-asyncio>=1.6.0,<2.0.0", "click>=8.1.3,<9.0.0", "tomli>=2.0.1,<3.0.0", diff --git a/backend/tests/test_mcp.py b/backend/tests/test_mcp.py index 0a87731a7c..0a5802ae93 100644 --- a/backend/tests/test_mcp.py +++ b/backend/tests/test_mcp.py @@ -13,6 +13,8 @@ from chainlit.auth import get_current_user from chainlit.mcp import ( + _MCP_HTTP_SSE_READ_TIMEOUT, + _MCP_HTTP_TIMEOUT, _RESTRICTED_HEADERS, HttpMcpConnection, McpDestinationError, @@ -20,7 +22,9 @@ StdioMcpConnection, _destination_in_allowlist, _destination_on_origin, + _mcp_http_module, make_mcp_http_client_factory, + make_mcp_streamable_http_client, validate_mcp_headers, validate_mcp_url, ) @@ -626,12 +630,12 @@ async def test_disables_redirects(self): async def test_default_timeout_is_30_seconds(self): client = make_mcp_http_client_factory(_noop_check)() try: - assert client.timeout == httpx.Timeout(30.0) + assert client.timeout == _mcp_http_module().Timeout(30.0) finally: await client.aclose() async def test_passed_timeout_is_honored(self): - custom_timeout = httpx.Timeout(5.0) + custom_timeout = _mcp_http_module().Timeout(5.0) client = make_mcp_http_client_factory(_noop_check)(timeout=custom_timeout) try: assert client.timeout == custom_timeout @@ -646,7 +650,7 @@ async def test_passed_headers_are_honored(self): await client.aclose() async def test_passed_auth_is_honored(self): - class DummyAuth(httpx.Auth): + class DummyAuth(_mcp_http_module().Auth): def auth_flow(self, request): yield request @@ -667,12 +671,34 @@ def test_sse_client_accepts_httpx_client_factory_kwarg(self): sig = inspect.signature(sse_client) assert "httpx_client_factory" in sig.parameters - def test_streamablehttp_client_accepts_httpx_client_factory_kwarg(self): - """Same regression guard as above, for the streamable-http transport.""" - from mcp.client.streamable_http import streamablehttp_client - - sig = inspect.signature(streamablehttp_client) - assert "httpx_client_factory" in sig.parameters + def test_streamable_http_client_accepts_http_client_kwarg(self): + """Same regression guard as above, for the streamable-http transport. + + That transport takes a ready-made `http_client=` rather than a + factory (the `streamablehttp_client` wrapper that took one was + removed in mcp 2.0.0), so this parameter is how our guarded client + gets in. If a future SDK drops it, connect_mcp would silently fall + back to the SDK's own client — follow_redirects=True and no + destination hook — reopening 1.5a.""" + from mcp.client.streamable_http import streamable_http_client + + sig = inspect.signature(streamable_http_client) + assert "http_client" in sig.parameters + + async def test_resolved_http_module_matches_what_the_sdk_builds(self): + """`mcp<2` dispatches with `httpx`, `mcp>=2` with `httpx2`, and the + two are not interchangeable at runtime. `_mcp_http_module` reads the + choice off the SDK rather than guessing from what is importable; pin + it against the client the SDK's own factory actually returns, so an + SDK that changes the binding fails here instead of at connect time + with a client the transport rejects.""" + from mcp.shared._httpx_utils import create_mcp_http_client + + client = create_mcp_http_client() + try: + assert type(client) is _mcp_http_module().AsyncClient + finally: + await client.aclose() async def test_request_hook_calls_check_destination_for_every_request(self): """The whole point of hooking the client (rather than validating the @@ -723,6 +749,70 @@ def check(url: str) -> None: assert "evil.example.com" in str(holder[0]) +class TestMakeMcpStreamableHttpClient: + """The streamable-http transport takes a ready-made client, so the + guarantees the factory used to get from the SDK's own wrapper now have to + hold on the client we build ourselves.""" + + async def test_disables_redirects(self): + """Same guard as the factory's: this client reaches the transport + directly, so if it ever ships with redirects enabled the + SSRF-via-redirect hole (1.5a) is open on streamable-http.""" + client = make_mcp_streamable_http_client( + make_mcp_http_client_factory(_noop_check) + ) + try: + assert client.follow_redirects is False + finally: + await client.aclose() + + async def test_read_timeout_covers_long_lived_streams(self): + """The removed `streamablehttp_client` wrapper built its client with + `Timeout(30, read=300)`. Passing `http_client=` makes that ours to + set, and falling through to the factory's bare 30s default would cut + a long-lived GET stream at 30 seconds instead of 300.""" + http = _mcp_http_module() + client = make_mcp_streamable_http_client( + make_mcp_http_client_factory(_noop_check) + ) + try: + assert client.timeout == http.Timeout( + _MCP_HTTP_TIMEOUT, read=_MCP_HTTP_SSE_READ_TIMEOUT + ) + finally: + await client.aclose() + + async def test_headers_are_applied(self): + """`streamable_http_client` has no `headers=` parameter, so the + connection's headers only reach the wire if they are set on this + client.""" + client = make_mcp_streamable_http_client( + make_mcp_http_client_factory(_noop_check), + headers={"Authorization": "Bearer token"}, + ) + try: + assert client.headers["authorization"] == "Bearer token" + finally: + await client.aclose() + + async def test_destination_hook_is_wired(self): + """The client carries the same per-request destination check as the + SSE path — it is built from the factory already bound to this + connection's grant, so the two cannot drift apart.""" + calls = [] + + client = make_mcp_streamable_http_client( + make_mcp_http_client_factory(calls.append) + ) + try: + hook = client.event_hooks["request"][0] + await hook(httpx.Request("GET", "https://example.com/anything")) + finally: + await client.aclose() + + assert calls == ["https://example.com/anything"] + + class TestDestinationInAllowlistHook: """1.3a fix: the SSE transport takes its POST target from the server's `endpoint` event, and the SDK only validates that event's netloc/scheme — @@ -882,8 +972,9 @@ async def list_tools(self): return await fake_list_tools() # What the transports were actually handed. Without this a test can only - # check that the factory was *built*, not that it reached the transport -- - # so dropping the httpx_client_factory kwarg would go unnoticed. + # check that the guarded client was *built*, not that it reached the + # transport -- so dropping the httpx_client_factory kwarg (SSE) or the + # http_client kwarg (streamable-http) would go unnoticed. captured: dict = {} @asynccontextmanager @@ -893,16 +984,15 @@ async def fake_sse_client(url, headers=None, httpx_client_factory=None, **kwargs yield (AsyncMock(), AsyncMock()) @asynccontextmanager - async def fake_streamablehttp_client( - url, headers=None, httpx_client_factory=None, **kwargs - ): + async def fake_streamable_http_client(url, http_client=None, **kwargs): captured["url"] = url - captured["httpx_client_factory"] = httpx_client_factory + captured["http_client"] = http_client yield (AsyncMock(), AsyncMock(), AsyncMock()) monkeypatch.setattr("mcp.client.sse.sse_client", fake_sse_client) monkeypatch.setattr( - "mcp.client.streamable_http.streamablehttp_client", fake_streamablehttp_client + "mcp.client.streamable_http.streamable_http_client", + fake_streamable_http_client, ) monkeypatch.setattr("mcp.ClientSession", FakeClientSession) @@ -1789,15 +1879,13 @@ def test_user_provided_failure_returns_useful_detail( ] @asynccontextmanager - async def failing_streamablehttp_client( - url, headers=None, httpx_client_factory=None, **kwargs - ): + async def failing_streamable_http_client(url, http_client=None, **kwargs): raise httpx.ConnectError(f"All connection attempts failed to {url}") yield # pragma: no cover - unreachable; required for generator shape monkeypatch.setattr( - "mcp.client.streamable_http.streamablehttp_client", - failing_streamablehttp_client, + "mcp.client.streamable_http.streamable_http_client", + failing_streamable_http_client, ) response = test_client.post( @@ -2161,10 +2249,11 @@ class TestConnectMcpBindsDestination: The unit tests elsewhere prove the factory and its hook behave correctly in isolation, and the endpoint tests prove connect_mcp responds correctly -- - but neither notices if the `httpx_client_factory=` argument is dropped, so - the factory would be built and silently discarded and every request would + but neither notices if the argument carrying it is dropped -- + `httpx_client_factory=` for SSE, `http_client=` for streamable-http -- so + the guard would be built and silently discarded and every request would go out unchecked. That is the SPL-2026-002 bypass, so it needs its own - guard: take the factory the transport was handed and prove it blocks. + guard: take what the transport was handed and prove it blocks. """ @staticmethod @@ -2257,6 +2346,54 @@ async def test_named_server_transport_gets_origin_bound_factory( ) assert not await self._hook_verdict(factory, "https://evil.example.com/sse") + @pytest.mark.asyncio + async def test_streamable_http_transport_gets_bound_client( + self, + test_client: TestClient, + test_config, + mcp_session_get_by_id_patched: Mock, + mock_get_current_user: Mock, + mock_mcp_transport, + ): + """Same guard for streamable-http, which carries the grant on + `http_client=` rather than a factory. Dropping it would leave the SDK + to build its own client -- follow_redirects=True, no destination hook + -- so assert on the client the transport was actually handed.""" + mock_get_current_user.return_value = None + test_config.features.mcp.enabled = True + test_config.features.mcp.user_servers.enabled = True + test_config.features.mcp.user_servers.allowed_urls = [ + "https://allowed.example.com/mcp/alice" + ] + + response = test_client.post( + "/mcp", + json={ + "sessionId": mcp_session_get_by_id_patched.id, + "name": "custom", + "url": "https://allowed.example.com/mcp/alice", + "clientType": "streamable-http", + }, + ) + assert response.status_code == 200 + + client = mock_mcp_transport.captured["http_client"] + assert client is not None, "transport was not given a bound http client" + assert client.follow_redirects is False + + hook = client.event_hooks["request"][0] + + async def allows(url: str) -> bool: + try: + await hook(httpx.Request("POST", url)) + return True + except McpDestinationError: + return False + + assert await allows("https://allowed.example.com/mcp/alice/messages/?s=1") + assert not await allows("https://allowed.example.com/admin") + assert not await allows("https://evil.example.com/mcp") + class TestConnectMcpStdioEnv: """StdioMcpServer.env restores the environment-variable support the diff --git a/uv.lock b/uv.lock index b82419825c..3fa37e2fc9 100644 --- a/uv.lock +++ b/uv.lock @@ -782,7 +782,7 @@ requires-dist = [ { name = "literalai", specifier = "==0.1.201" }, { name = "llama-index", marker = "extra == 'tests'", specifier = ">=0.13.0,<1.0.0" }, { name = "matplotlib", marker = "extra == 'tests'", specifier = ">=3.7.1,<4.0.0" }, - { name = "mcp", specifier = ">=1.28.1,<2.0.0" }, + { name = "mcp", specifier = ">=1.28.1,<3.0.0" }, { name = "moto", marker = "extra == 'tests'", specifier = ">=5.0.14,<6.0.0" }, { name = "mypy", marker = "extra == 'mypy'", specifier = ">=1.13,<2.0.0" }, { name = "mypy-boto3-dynamodb", marker = "extra == 'mypy'", specifier = ">=1.34.113,<2.0.0" }, From 4628edc365ee6ce37254d543fe4de4672436164f Mon Sep 17 00:00:00 2001 From: Aniket Wagh Date: Fri, 28 Aug 2026 16:53:33 +0530 Subject: [PATCH 2/4] fix(mcp): address review feedback on mcp 2.x support Addresses dokterbob's review on PR #3030, verified by live testing against mcp 2.1.1 rather than by inspection: - Add a CI job that overrides the locked mcp with >=2,<3 and runs tests/test_mcp.py. The existing matrix always resolves mcp 1.29.1 from the lockfile, so the httpx2 branch of _mcp_http_module() and the guard added specifically to catch an SDK rebinding (test_resolved_http_module_matches_what_the_sdk_builds) never ran under mcp 2.x and passed vacuously. Verified both ways locally: the full suite passes with mcp>=2 actually installed, and breaking the httpx2 branch makes exactly that guard fail under this job while it would have stayed green under the old matrix. - Update the comment at validate_mcp_url's httpx.URL parse to say the httpx/httpx2 equivalence has been checked, not assert it as if httpx were still the only flavour in play. - fake_streamable_http_client now yields a 2-tuple, matching what streamable_http_client actually returns under mcp>=2 (the 1.x get_session_id callable is gone). Production code already only reads transport[:2], but the 3-tuple mock couldn't catch a stray transport[2] the way the real 2.x transport would. - test_destination_hook_is_wired now builds its httpx.Request through _mcp_http_module(), so it exercises the request flavour the client actually hands the hook under mcp>=2 instead of always httpx. - Use the _MCP_HTTP_TIMEOUT constant instead of a duplicated 30.0 literal in the factory's default (cubic). Full backend suite (938 tests), lint, format and mypy all clean. Co-Authored-By: Claude Opus 5 (1M context) --- .github/workflows/tests.yaml | 23 +++++++++++++++++++++++ backend/chainlit/mcp.py | 11 +++++++---- backend/tests/test_mcp.py | 13 +++++++++++-- 3 files changed, 41 insertions(+), 6 deletions(-) diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index 826bcecaf3..2596ba5094 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -26,3 +26,26 @@ jobs: run: uv run --no-project pytest --cov=chainlit/ - name: Run frontend tests run: pnpm run test + + mcp-2x-compat: + # mcp is pinned to >=1.28.1 in the lockfile, so the matrix above never + # exercises the mcp>=2 codepaths (the httpx2 client, streamable_http_client's + # http_client= kwarg). Overriding the installed version here so a future + # SDK release that breaks that surface fails a check instead of only + # breaking users who resolve onto 2.x, which the version range already + # permits (backend/pyproject.toml: mcp>=1.28.1,<3.0.0). + runs-on: ubuntu-latest + name: MCP tests against mcp 2.x + env: + BACKEND_DIR: ./backend + steps: + - uses: actions/checkout@v6 + - uses: ./.github/actions/uv-python-install + name: Install Python, uv and Python dependencies + with: + python-version: '3.13' + uv-args: --extra tests --extra custom-data + - name: Override the locked mcp with the latest 2.x + run: uv pip install 'mcp>=2,<3' + - name: Run MCP tests + run: uv run --no-project pytest backend/tests/test_mcp.py diff --git a/backend/chainlit/mcp.py b/backend/chainlit/mcp.py index 6b779eb115..c3e4555ab6 100644 --- a/backend/chainlit/mcp.py +++ b/backend/chainlit/mcp.py @@ -138,9 +138,12 @@ def validate_mcp_url(url: str, allowed_urls: list[str]) -> None: "Configure features.mcp.user_servers.allowed_urls in your config." ) - # Parse the request URL through httpx, which is what the MCP transports - # dispatch with. Validating anything else risks approving a URL that - # differs from the one that actually goes on the wire. + # Parse with chainlit's own httpx rather than the installed SDK's flavour + # (httpx on mcp<2, httpx2 on mcp>=2). Deliberate: URL parsing showed zero + # divergence between the two across traversal, IDN, userinfo, port and + # encoded-separator cases, and validating anything other than what the + # transport actually dispatches with risks approving a URL that differs + # from the one that goes on the wire. try: parsed = httpx.URL(url) except Exception as exc: @@ -334,7 +337,7 @@ async def _check_request(request: httpx.Request) -> None: return http.AsyncClient( follow_redirects=False, - timeout=timeout if timeout is not None else http.Timeout(30.0), + timeout=timeout if timeout is not None else http.Timeout(_MCP_HTTP_TIMEOUT), headers=headers, auth=auth, event_hooks={"request": [_check_request]}, diff --git a/backend/tests/test_mcp.py b/backend/tests/test_mcp.py index 0a5802ae93..2a38b746dd 100644 --- a/backend/tests/test_mcp.py +++ b/backend/tests/test_mcp.py @@ -806,7 +806,12 @@ async def test_destination_hook_is_wired(self): ) try: hook = client.event_hooks["request"][0] - await hook(httpx.Request("GET", "https://example.com/anything")) + # Built from the same resolved module as the client itself + # (httpx on mcp<2, httpx2 on mcp>=2) so this exercises the + # request flavour the transport actually hands the hook, not + # whichever one happens to be importable. + request = _mcp_http_module().Request("GET", "https://example.com/anything") + await hook(request) finally: await client.aclose() @@ -985,9 +990,13 @@ async def fake_sse_client(url, headers=None, httpx_client_factory=None, **kwargs @asynccontextmanager async def fake_streamable_http_client(url, http_client=None, **kwargs): + # Real mcp>=2 streamable_http_client yields a 2-tuple (the + # get_session_id callable from 1.x is gone); matching that shape here + # means a stray transport[2] fails this test instead of only failing + # against the real 2.x transport. captured["url"] = url captured["http_client"] = http_client - yield (AsyncMock(), AsyncMock(), AsyncMock()) + yield (AsyncMock(), AsyncMock()) monkeypatch.setattr("mcp.client.sse.sse_client", fake_sse_client) monkeypatch.setattr( From 9abed5ede9a30c1214fff1b3f0fb7146d95493f0 Mon Sep 17 00:00:00 2001 From: aniketwaghh Date: Mon, 31 Aug 2026 09:00:04 +0530 Subject: [PATCH 3/4] ci(mcp): default CI to mcp 2.x and deprecate 1.x Follows dokterbob's direction on PR #3030: chainlit should not carry the cost of maintaining and testing two SDK lines. - uv lock -P mcp moves the lockfile to mcp 2.1.1, so the existing matrix resolves 2.x on every job instead of 1.29.1. The lock also moves pydantic (2.11.10 -> 2.13.5), semantic-kernel and azure-ai-agents, which mcp 2.x forces: semantic-kernel depends on mcp and had to move to a release that accepts it. - Drop the mcp-2x-compat job added in 4628edc. It existed only because the lock pinned 1.x and the 2.x codepaths were therefore never exercised; with 2.x as the default resolve, it is a second permutation buying nothing. - Warn on import when the resolved SDK is still 1.x. The floor stays at >=1.28.1 so nobody pinned there breaks today, but 1.x is no longer covered by CI and the intent is to raise the floor later, so users get notice first. - Cast the factory and client handed to sse_client and streamable_http_client. Their runtime flavour follows the installed SDK (httpx under 1.x, httpx2 under 2.x) and is not knowable statically; with the lock on 2.x, mypy now checks against the httpx2 signatures and flagged the httpx-flavoured annotations. Verified on the new lock: 938 backend tests, lint, format and mypy all clean. test_mcp.py's 146 tests pass under both mcp 1.29.1 and 2.1.1, so dropping the compat job is not hiding a break in the still-supported floor. The warning fires under 1.29.1 and is silent under 2.1.1. --- .github/workflows/tests.yaml | 23 ---- backend/chainlit/mcp.py | 24 ++++ backend/chainlit/server.py | 13 +- uv.lock | 255 +++++++++++++++++++++-------------- 4 files changed, 187 insertions(+), 128 deletions(-) diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index 2596ba5094..826bcecaf3 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -26,26 +26,3 @@ jobs: run: uv run --no-project pytest --cov=chainlit/ - name: Run frontend tests run: pnpm run test - - mcp-2x-compat: - # mcp is pinned to >=1.28.1 in the lockfile, so the matrix above never - # exercises the mcp>=2 codepaths (the httpx2 client, streamable_http_client's - # http_client= kwarg). Overriding the installed version here so a future - # SDK release that breaks that surface fails a check instead of only - # breaking users who resolve onto 2.x, which the version range already - # permits (backend/pyproject.toml: mcp>=1.28.1,<3.0.0). - runs-on: ubuntu-latest - name: MCP tests against mcp 2.x - env: - BACKEND_DIR: ./backend - steps: - - uses: actions/checkout@v6 - - uses: ./.github/actions/uv-python-install - name: Install Python, uv and Python dependencies - with: - python-version: '3.13' - uv-args: --extra tests --extra custom-data - - name: Override the locked mcp with the latest 2.x - run: uv pip install 'mcp>=2,<3' - - name: Run MCP tests - run: uv run --no-project pytest backend/tests/test_mcp.py diff --git a/backend/chainlit/mcp.py b/backend/chainlit/mcp.py index c3e4555ab6..0b76f64b04 100644 --- a/backend/chainlit/mcp.py +++ b/backend/chainlit/mcp.py @@ -1,3 +1,5 @@ +import warnings +from importlib.metadata import version from types import ModuleType from typing import Callable, Dict, Literal, Optional, Union from urllib.parse import unquote, urlparse @@ -255,6 +257,28 @@ def check(url: str) -> None: _MCP_HTTP_SSE_READ_TIMEOUT = 300.0 +def _warn_if_mcp_1x() -> None: + """Warn once, at import, when the resolved MCP SDK is still on 1.x. + + chainlit supports ``mcp>=1.28.1,<3.0.0`` but only resolves and tests + against 2.x. 1.x still works today and the floor is deliberately left + where it is, so this is a heads-up rather than a breakage: the intent is + to raise the floor to ``>=2`` once 1.x stops being worth carrying, and + anyone pinned below that wants notice before it happens. + """ + if version("mcp").startswith("1."): + warnings.warn( + "chainlit resolved mcp 1.x. Support for mcp<2 is deprecated and " + "will be removed in a future release; pin mcp>=2 to stay ahead " + "of it.", + DeprecationWarning, + stacklevel=2, + ) + + +_warn_if_mcp_1x() + + def _mcp_http_module() -> ModuleType: """Return the HTTP library the installed MCP SDK dispatches with. diff --git a/backend/chainlit/server.py b/backend/chainlit/server.py index f90322b12b..ceba6de601 100644 --- a/backend/chainlit/server.py +++ b/backend/chainlit/server.py @@ -10,7 +10,7 @@ import webbrowser from contextlib import AsyncExitStack, asynccontextmanager from pathlib import Path -from typing import TYPE_CHECKING, Dict, List, Optional, Union, cast +from typing import TYPE_CHECKING, Any, Dict, List, Optional, Union, cast import socketio from fastapi import ( @@ -1659,7 +1659,13 @@ async def _mcp_session_runner() -> None: sse_client( url=mcp_connection.url, headers=mcp_connection.headers, - httpx_client_factory=mcp_http_client_factory, + # The factory builds its client from whichever HTTP + # library the installed SDK dispatches with, which is + # only known at runtime (see _mcp_http_module). Under + # mcp>=2 that is httpx2, so the httpx-flavoured + # annotation no longer matches the SDK's parameter + # type even though the object is the right one. + httpx_client_factory=cast(Any, mcp_http_client_factory), ) ) elif isinstance(mcp_connection, StdioMcpConnection): @@ -1691,7 +1697,8 @@ async def _mcp_session_runner() -> None: transport = await exit_stack.enter_async_context( streamable_http_client( url=mcp_connection.url, - http_client=http_client, + # Same runtime-flavour mismatch as the SSE branch. + http_client=cast(Any, http_client), ) ) else: diff --git a/uv.lock b/uv.lock index 3fa37e2fc9..06e1876d3a 100644 --- a/uv.lock +++ b/uv.lock @@ -394,16 +394,16 @@ wheels = [ [[package]] name = "azure-ai-agents" -version = "1.1.0" +version = "1.2.0b6" source = { registry = "https://pypi.org/simple" } dependencies = [ { name = "azure-core" }, { name = "isodate" }, { name = "typing-extensions" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/39/98/bbe2e9e5b0a934be1930545025bf7018ebc4cc33b10134cc3314d6487076/azure_ai_agents-1.1.0.tar.gz", hash = "sha256:eb9d7226282d03206c3fab3f3ee0a2fc71e0ad38e52d2f4f19a92c56ed951aea", size = 303656, upload-time = "2025-08-05T19:02:26.7Z" } +sdist = { url = "https://files.pythonhosted.org/packages/68/32/f4e534dc05dfb714705df56a190d690c5452cd4dd7e936612cb1adddc44f/azure_ai_agents-1.2.0b6.tar.gz", hash = "sha256:d3c10848c3b19dec98a292f8c10cee4ba4aac1050d4faabf9c2e2456b727f528", size = 396865, upload-time = "2025-10-24T18:04:47.877Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/e6/31/43750555bf20d3d2d7589fcd775c96ce7c96e58e208b81c1ed6d4bad6c5f/azure_ai_agents-1.1.0-py3-none-any.whl", hash = "sha256:f660bb0d564aeb88e33140ebc1e4700d2e36e2e12ee60c3346915d702a9310a9", size = 191126, upload-time = "2025-08-05T19:02:28.178Z" }, + { url = "https://files.pythonhosted.org/packages/96/d0/930c522f5fa9da163de057e57f8b44539424e13f46618c52624ebc712293/azure_ai_agents-1.2.0b6-py3-none-any.whl", hash = "sha256:ce23ad8fb9791118905be1ec8eae5c907cca2e536a455f1d3b830062c72cf2a7", size = 217950, upload-time = "2025-10-24T18:04:49.72Z" }, ] [[package]] @@ -1813,6 +1813,19 @@ wheels = [ { url = "https://files.pythonhosted.org/packages/7e/f5/f66802a942d491edb555dd61e3a9961140fd64c90bce1eafd741609d334d/httpcore-1.0.9-py3-none-any.whl", hash = "sha256:2d400746a40668fc9dec9810239072b40b4484b640a8c38fd654a024c7a1bf55", size = 78784, upload-time = "2025-04-24T22:06:20.566Z" }, ] +[[package]] +name = "httpcore2" +version = "2.12.0" +source = { registry = "https://pypi.org/simple" } +dependencies = [ + { name = "h11" }, + { name = "truststore" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/be/ad/f4f0e57345f1870f3e8cb624e058d7eca6e5a27d33bcc3311d9b618734cd/httpcore2-2.12.0.tar.gz", hash = "sha256:9293522bba0aa7c4c8e9e3f040c16575bd8868e155a77fa30c7a9085a5eae648", size = 67548, upload-time = "2026-08-18T13:22:08.211Z" } +wheels = [ + { url = "https://files.pythonhosted.org/packages/d2/74/d370e55600d9bcfa0d9794b0166126d49291a3d2b20c268fc98c453a4948/httpcore2-2.12.0-py3-none-any.whl", hash = "sha256:7e04258ce01013d7d615e5b910a3b27fac937d7a95038227e79652b4ba3b4ceb", size = 83074, upload-time = "2026-08-18T13:22:05.854Z" }, +] + [[package]] name = "httpx" version = "0.28.1" @@ -1829,12 +1842,29 @@ wheels = [ ] [[package]] -name = "httpx-sse" -version = "0.4.3" +name = "httpx2" +version = "2.12.0" source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/0f/4c/751061ffa58615a32c31b2d82e8482be8dd4a89154f003147acee90f2be9/httpx_sse-0.4.3.tar.gz", hash = "sha256:9b1ed0127459a66014aec3c56bebd93da3c1bc8bb6618c8082039a44889a755d", size = 15943, upload-time = "2025-10-10T21:48:22.271Z" } +dependencies = [ + { name = "anyio", marker = "sys_platform != 'emscripten'" }, + { name = "httpcore2", marker = "sys_platform != 'emscripten'" }, + { name = "httpx2-jsfetch", marker = "python_full_version >= '3.12' and sys_platform == 'emscripten'" }, + { name = "idna" }, + { name = "truststore", marker = "sys_platform != 'emscripten'" }, + { name = "typing-extensions", marker = "python_full_version < '3.13'" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/7f/f8/579a8b51e42e38ee32647df9f08aa25643ae788e275cc625b199829c4671/httpx2-2.12.0.tar.gz", hash = "sha256:7631fe9887a8a2275f4a2540e053aa670fcc50742864a9ae7c66e609fdcf12cf", size = 100040, upload-time = "2026-08-18T13:22:09.086Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/d2/fd/6668e5aec43ab844de6fc74927e155a3b37bf40d7c3790e49fc0406b6578/httpx_sse-0.4.3-py3-none-any.whl", hash = "sha256:0ac1c9fe3c0afad2e0ebb25a934a59f4c7823b60792691f779fad2c5568830fc", size = 8960, upload-time = "2025-10-10T21:48:21.158Z" }, + { url = "https://files.pythonhosted.org/packages/c8/95/411ba65569158e862368917aaf56597f3e5fa3b91b0502919638465a08f3/httpx2-2.12.0-py3-none-any.whl", hash = "sha256:cc8b6eecb8661c146b8f89a60e97456ee086e91a784ed31ac450c3a9e613dd36", size = 95427, upload-time = "2026-08-18T13:22:06.834Z" }, +] + +[[package]] +name = "httpx2-jsfetch" +version = "1.0" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/cd/c4/0e5636363151a2a1795e0a77617168b9ca438e1748ec05fc9b5687f93d64/httpx2_jsfetch-1.0.tar.gz", hash = "sha256:70a0e3eabfef7cce5ad9c629f7d01ca05e418f586646f4ddf14782e4c1454c60", size = 6872, upload-time = "2026-08-07T00:13:07.492Z" } +wheels = [ + { url = "https://files.pythonhosted.org/packages/9b/43/832f631d32e4f1211caa2ba368317739fe71f0b8530e4c9d15dc454bac2a/httpx2_jsfetch-1.0-py3-none-any.whl", hash = "sha256:cb916b707601e69a07721aabc8f3f6659be3a6893bc1ff5c6f9e02241df2da32", size = 6382, upload-time = "2026-08-07T00:13:06.567Z" }, ] [[package]] @@ -1859,11 +1889,11 @@ wheels = [ [[package]] name = "idna" -version = "3.11" +version = "3.19" source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/6f/6d/0703ccc57f3a7233505399edb88de3cbd678da106337b9fcde432b65ed60/idna-3.11.tar.gz", hash = "sha256:795dafcc9c04ed0c1fb032c2aa73654d8e8c5023a7df64a53f39190ada629902", size = 194582, upload-time = "2025-10-12T14:55:20.501Z" } +sdist = { url = "https://files.pythonhosted.org/packages/5f/f7/abb373e5757eaec4b922b92f97ec8d6d7e057cf06778247604fbc4e7c3f3/idna-3.19.tar.gz", hash = "sha256:5e0811a4383b21dc5838069f801c4fb62113b7447663d2530d2bd6e77b49bf15", size = 215237, upload-time = "2026-08-18T05:14:24.27Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/0e/61/66938bbb5fc52dbdf84594873d5b51fb1f7c7794e9c0f5bd885f30bc507b/idna-3.11-py3-none-any.whl", hash = "sha256:771a87f49d9defaf64091e6e6fe9c18d4833f140bd19464795bc32d966ca37ea", size = 71008, upload-time = "2025-10-12T14:55:18.883Z" }, + { url = "https://files.pythonhosted.org/packages/57/b0/0e52c878c53f245edd3a11020f20979b3f490f245af532c7cae3027754b5/idna-3.19-py3-none-any.whl", hash = "sha256:815e7be7a7806d54abb586dc943addc79e8b2ee16915059658cbeff4b1b43bf4", size = 68550, upload-time = "2026-08-18T05:14:22.343Z" }, ] [[package]] @@ -2753,15 +2783,15 @@ wheels = [ [[package]] name = "mcp" -version = "1.29.1" +version = "2.1.1" source = { registry = "https://pypi.org/simple" } dependencies = [ { name = "anyio" }, - { name = "httpx" }, - { name = "httpx-sse" }, + { name = "httpx2" }, { name = "jsonschema" }, + { name = "mcp-types" }, + { name = "opentelemetry-api" }, { name = "pydantic" }, - { name = "pydantic-settings" }, { name = "pyjwt", extra = ["crypto"] }, { name = "python-multipart" }, { name = "pywin32", marker = "sys_platform == 'win32'" }, @@ -2771,9 +2801,22 @@ dependencies = [ { name = "typing-inspection" }, { name = "uvicorn", marker = "sys_platform != 'emscripten'" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/b5/48/0bb26fdfe7ac16875f534a101ce2405eae192bdef37e7451f2f4507c13ec/mcp-1.29.1.tar.gz", hash = "sha256:1967ba4c315f7a375146209949f45950d18b0efd2f913d7cf3400bc723ee5f04", size = 646823, upload-time = "2026-08-24T18:30:41.161Z" } +sdist = { url = "https://files.pythonhosted.org/packages/d4/6e/21fb8e5d579dbe21d96ea4d5034200d46d8bdf2261053b5bd041f3c2f612/mcp-2.1.1.tar.gz", hash = "sha256:50b7ba1ebbe117008ea7bdd288234043e69c20b403d6851d19661e6d431a75ef", size = 3984589, upload-time = "2026-08-25T16:14:02.376Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/0b/04/d6b4fb82eefe9e81807aabca1ac98f460ae0883974b83a997aaa20c52545/mcp-1.29.1-py3-none-any.whl", hash = "sha256:b6310eeb59153300c4ab8b9aec4c52f4819a2d6a8e429eb43d908bed7c783648", size = 224653, upload-time = "2026-08-24T18:30:39.573Z" }, + { url = "https://files.pythonhosted.org/packages/50/af/8644cc5fa26a59afd2df2e98eeb19e72926887fa4b7441aba4ff661140db/mcp-2.1.1-py3-none-any.whl", hash = "sha256:1c6c31c5d6471c58db76af3af8af67f46d11d01f0a59077d0a308cbdb3d3e915", size = 357912, upload-time = "2026-08-25T16:13:59.024Z" }, +] + +[[package]] +name = "mcp-types" +version = "2.1.1" +source = { registry = "https://pypi.org/simple" } +dependencies = [ + { name = "pydantic" }, + { name = "typing-extensions" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/6a/dd/1c4417dc0b722c23a1669032d5f044e41170fe5d4773b488a50fcce98c32/mcp_types-2.1.1.tar.gz", hash = "sha256:77dcbe48fba73cca71a673f2646a5f037a017b7a0a07ac89cec1113028890eda", size = 66674, upload-time = "2026-08-25T16:14:03.861Z" } +wheels = [ + { url = "https://files.pythonhosted.org/packages/71/d0/242e63c510f4a17381f55b1549a3f94f5687a0595984febd2b6f87a687a0/mcp_types-2.1.1-py3-none-any.whl", hash = "sha256:26f9f7f03f2a5730717a5b98e2ab7eb640ac352d05a00cdc725c311864778295", size = 69656, upload-time = "2026-08-25T16:14:00.667Z" }, ] [[package]] @@ -4359,7 +4402,7 @@ wheels = [ [[package]] name = "pydantic" -version = "2.11.10" +version = "2.13.5" source = { registry = "https://pypi.org/simple" } dependencies = [ { name = "annotated-types" }, @@ -4367,96 +4410,95 @@ dependencies = [ { name = "typing-extensions" }, { name = "typing-inspection" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/ae/54/ecab642b3bed45f7d5f59b38443dcb36ef50f85af192e6ece103dbfe9587/pydantic-2.11.10.tar.gz", hash = "sha256:dc280f0982fbda6c38fada4e476dc0a4f3aeaf9c6ad4c28df68a666ec3c61423", size = 788494, upload-time = "2025-10-04T10:40:41.338Z" } +sdist = { url = "https://files.pythonhosted.org/packages/53/ef/fc4f868f4e2cee79f863883abffceff107875f569b848507319842d2a681/pydantic-2.13.5.tar.gz", hash = "sha256:51a9c5f7b2f8e636f04c6cada605d9b6a3bf1348fdf945a3d8869b19bba0ee08", size = 845750, upload-time = "2026-08-28T14:04:00.916Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/bd/1f/73c53fcbfb0b5a78f91176df41945ca466e71e9d9d836e5c522abda39ee7/pydantic-2.11.10-py3-none-any.whl", hash = "sha256:802a655709d49bd004c31e865ef37da30b540786a46bfce02333e0e24b5fe29a", size = 444823, upload-time = "2025-10-04T10:40:39.055Z" }, + { url = "https://files.pythonhosted.org/packages/eb/47/c95ffc2009878c7aac0c5e08528022dcb885933252a88b5f170058014464/pydantic-2.13.5-py3-none-any.whl", hash = "sha256:346a034f080da3755d8e9cb5e00e8b07de1d39e4f6e2c87d8ab7cafa0b269a73", size = 472589, upload-time = "2026-08-28T14:03:59.136Z" }, ] [[package]] name = "pydantic-core" -version = "2.33.2" +version = "2.46.5" source = { registry = "https://pypi.org/simple" } dependencies = [ { name = "typing-extensions" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/ad/88/5f2260bdfae97aabf98f1778d43f69574390ad787afb646292a638c923d4/pydantic_core-2.33.2.tar.gz", hash = "sha256:7cb8bc3605c29176e1b105350d2e6474142d7c1bd1d9327c4a9bdb46bf827acc", size = 435195, upload-time = "2025-04-23T18:33:52.104Z" } -wheels = [ - { url = "https://files.pythonhosted.org/packages/e5/92/b31726561b5dae176c2d2c2dc43a9c5bfba5d32f96f8b4c0a600dd492447/pydantic_core-2.33.2-cp310-cp310-macosx_10_12_x86_64.whl", hash = "sha256:2b3d326aaef0c0399d9afffeb6367d5e26ddc24d351dbc9c636840ac355dc5d8", size = 2028817, upload-time = "2025-04-23T18:30:43.919Z" }, - { url = "https://files.pythonhosted.org/packages/a3/44/3f0b95fafdaca04a483c4e685fe437c6891001bf3ce8b2fded82b9ea3aa1/pydantic_core-2.33.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e5b2671f05ba48b94cb90ce55d8bdcaaedb8ba00cc5359f6810fc918713983d", size = 1861357, upload-time = "2025-04-23T18:30:46.372Z" }, - { url = "https://files.pythonhosted.org/packages/30/97/e8f13b55766234caae05372826e8e4b3b96e7b248be3157f53237682e43c/pydantic_core-2.33.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0069c9acc3f3981b9ff4cdfaf088e98d83440a4c7ea1bc07460af3d4dc22e72d", size = 1898011, upload-time = "2025-04-23T18:30:47.591Z" }, - { url = "https://files.pythonhosted.org/packages/9b/a3/99c48cf7bafc991cc3ee66fd544c0aae8dc907b752f1dad2d79b1b5a471f/pydantic_core-2.33.2-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:d53b22f2032c42eaaf025f7c40c2e3b94568ae077a606f006d206a463bc69572", size = 1982730, upload-time = "2025-04-23T18:30:49.328Z" }, - { url = "https://files.pythonhosted.org/packages/de/8e/a5b882ec4307010a840fb8b58bd9bf65d1840c92eae7534c7441709bf54b/pydantic_core-2.33.2-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:0405262705a123b7ce9f0b92f123334d67b70fd1f20a9372b907ce1080c7ba02", size = 2136178, upload-time = "2025-04-23T18:30:50.907Z" }, - { url = "https://files.pythonhosted.org/packages/e4/bb/71e35fc3ed05af6834e890edb75968e2802fe98778971ab5cba20a162315/pydantic_core-2.33.2-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:4b25d91e288e2c4e0662b8038a28c6a07eaac3e196cfc4ff69de4ea3db992a1b", size = 2736462, upload-time = "2025-04-23T18:30:52.083Z" }, - { url = "https://files.pythonhosted.org/packages/31/0d/c8f7593e6bc7066289bbc366f2235701dcbebcd1ff0ef8e64f6f239fb47d/pydantic_core-2.33.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6bdfe4b3789761f3bcb4b1ddf33355a71079858958e3a552f16d5af19768fef2", size = 2005652, upload-time = "2025-04-23T18:30:53.389Z" }, - { url = "https://files.pythonhosted.org/packages/d2/7a/996d8bd75f3eda405e3dd219ff5ff0a283cd8e34add39d8ef9157e722867/pydantic_core-2.33.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:efec8db3266b76ef9607c2c4c419bdb06bf335ae433b80816089ea7585816f6a", size = 2113306, upload-time = "2025-04-23T18:30:54.661Z" }, - { url = "https://files.pythonhosted.org/packages/ff/84/daf2a6fb2db40ffda6578a7e8c5a6e9c8affb251a05c233ae37098118788/pydantic_core-2.33.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:031c57d67ca86902726e0fae2214ce6770bbe2f710dc33063187a68744a5ecac", size = 2073720, upload-time = "2025-04-23T18:30:56.11Z" }, - { url = "https://files.pythonhosted.org/packages/77/fb/2258da019f4825128445ae79456a5499c032b55849dbd5bed78c95ccf163/pydantic_core-2.33.2-cp310-cp310-musllinux_1_1_armv7l.whl", hash = "sha256:f8de619080e944347f5f20de29a975c2d815d9ddd8be9b9b7268e2e3ef68605a", size = 2244915, upload-time = "2025-04-23T18:30:57.501Z" }, - { url = "https://files.pythonhosted.org/packages/d8/7a/925ff73756031289468326e355b6fa8316960d0d65f8b5d6b3a3e7866de7/pydantic_core-2.33.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:73662edf539e72a9440129f231ed3757faab89630d291b784ca99237fb94db2b", size = 2241884, upload-time = "2025-04-23T18:30:58.867Z" }, - { url = "https://files.pythonhosted.org/packages/0b/b0/249ee6d2646f1cdadcb813805fe76265745c4010cf20a8eba7b0e639d9b2/pydantic_core-2.33.2-cp310-cp310-win32.whl", hash = "sha256:0a39979dcbb70998b0e505fb1556a1d550a0781463ce84ebf915ba293ccb7e22", size = 1910496, upload-time = "2025-04-23T18:31:00.078Z" }, - { url = "https://files.pythonhosted.org/packages/66/ff/172ba8f12a42d4b552917aa65d1f2328990d3ccfc01d5b7c943ec084299f/pydantic_core-2.33.2-cp310-cp310-win_amd64.whl", hash = "sha256:b0379a2b24882fef529ec3b4987cb5d003b9cda32256024e6fe1586ac45fc640", size = 1955019, upload-time = "2025-04-23T18:31:01.335Z" }, - { url = "https://files.pythonhosted.org/packages/3f/8d/71db63483d518cbbf290261a1fc2839d17ff89fce7089e08cad07ccfce67/pydantic_core-2.33.2-cp311-cp311-macosx_10_12_x86_64.whl", hash = "sha256:4c5b0a576fb381edd6d27f0a85915c6daf2f8138dc5c267a57c08a62900758c7", size = 2028584, upload-time = "2025-04-23T18:31:03.106Z" }, - { url = "https://files.pythonhosted.org/packages/24/2f/3cfa7244ae292dd850989f328722d2aef313f74ffc471184dc509e1e4e5a/pydantic_core-2.33.2-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:e799c050df38a639db758c617ec771fd8fb7a5f8eaaa4b27b101f266b216a246", size = 1855071, upload-time = "2025-04-23T18:31:04.621Z" }, - { url = "https://files.pythonhosted.org/packages/b3/d3/4ae42d33f5e3f50dd467761304be2fa0a9417fbf09735bc2cce003480f2a/pydantic_core-2.33.2-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dc46a01bf8d62f227d5ecee74178ffc448ff4e5197c756331f71efcc66dc980f", size = 1897823, upload-time = "2025-04-23T18:31:06.377Z" }, - { url = "https://files.pythonhosted.org/packages/f4/f3/aa5976e8352b7695ff808599794b1fba2a9ae2ee954a3426855935799488/pydantic_core-2.33.2-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:a144d4f717285c6d9234a66778059f33a89096dfb9b39117663fd8413d582dcc", size = 1983792, upload-time = "2025-04-23T18:31:07.93Z" }, - { url = "https://files.pythonhosted.org/packages/d5/7a/cda9b5a23c552037717f2b2a5257e9b2bfe45e687386df9591eff7b46d28/pydantic_core-2.33.2-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:73cf6373c21bc80b2e0dc88444f41ae60b2f070ed02095754eb5a01df12256de", size = 2136338, upload-time = "2025-04-23T18:31:09.283Z" }, - { url = "https://files.pythonhosted.org/packages/2b/9f/b8f9ec8dd1417eb9da784e91e1667d58a2a4a7b7b34cf4af765ef663a7e5/pydantic_core-2.33.2-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:3dc625f4aa79713512d1976fe9f0bc99f706a9dee21dfd1810b4bbbf228d0e8a", size = 2730998, upload-time = "2025-04-23T18:31:11.7Z" }, - { url = "https://files.pythonhosted.org/packages/47/bc/cd720e078576bdb8255d5032c5d63ee5c0bf4b7173dd955185a1d658c456/pydantic_core-2.33.2-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:881b21b5549499972441da4758d662aeea93f1923f953e9cbaff14b8b9565aef", size = 2003200, upload-time = "2025-04-23T18:31:13.536Z" }, - { url = "https://files.pythonhosted.org/packages/ca/22/3602b895ee2cd29d11a2b349372446ae9727c32e78a94b3d588a40fdf187/pydantic_core-2.33.2-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:bdc25f3681f7b78572699569514036afe3c243bc3059d3942624e936ec93450e", size = 2113890, upload-time = "2025-04-23T18:31:15.011Z" }, - { url = "https://files.pythonhosted.org/packages/ff/e6/e3c5908c03cf00d629eb38393a98fccc38ee0ce8ecce32f69fc7d7b558a7/pydantic_core-2.33.2-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:fe5b32187cbc0c862ee201ad66c30cf218e5ed468ec8dc1cf49dec66e160cc4d", size = 2073359, upload-time = "2025-04-23T18:31:16.393Z" }, - { url = "https://files.pythonhosted.org/packages/12/e7/6a36a07c59ebefc8777d1ffdaf5ae71b06b21952582e4b07eba88a421c79/pydantic_core-2.33.2-cp311-cp311-musllinux_1_1_armv7l.whl", hash = "sha256:bc7aee6f634a6f4a95676fcb5d6559a2c2a390330098dba5e5a5f28a2e4ada30", size = 2245883, upload-time = "2025-04-23T18:31:17.892Z" }, - { url = "https://files.pythonhosted.org/packages/16/3f/59b3187aaa6cc0c1e6616e8045b284de2b6a87b027cce2ffcea073adf1d2/pydantic_core-2.33.2-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:235f45e5dbcccf6bd99f9f472858849f73d11120d76ea8707115415f8e5ebebf", size = 2241074, upload-time = "2025-04-23T18:31:19.205Z" }, - { url = "https://files.pythonhosted.org/packages/e0/ed/55532bb88f674d5d8f67ab121a2a13c385df382de2a1677f30ad385f7438/pydantic_core-2.33.2-cp311-cp311-win32.whl", hash = "sha256:6368900c2d3ef09b69cb0b913f9f8263b03786e5b2a387706c5afb66800efd51", size = 1910538, upload-time = "2025-04-23T18:31:20.541Z" }, - { url = "https://files.pythonhosted.org/packages/fe/1b/25b7cccd4519c0b23c2dd636ad39d381abf113085ce4f7bec2b0dc755eb1/pydantic_core-2.33.2-cp311-cp311-win_amd64.whl", hash = "sha256:1e063337ef9e9820c77acc768546325ebe04ee38b08703244c1309cccc4f1bab", size = 1952909, upload-time = "2025-04-23T18:31:22.371Z" }, - { url = "https://files.pythonhosted.org/packages/49/a9/d809358e49126438055884c4366a1f6227f0f84f635a9014e2deb9b9de54/pydantic_core-2.33.2-cp311-cp311-win_arm64.whl", hash = "sha256:6b99022f1d19bc32a4c2a0d544fc9a76e3be90f0b3f4af413f87d38749300e65", size = 1897786, upload-time = "2025-04-23T18:31:24.161Z" }, - { url = "https://files.pythonhosted.org/packages/18/8a/2b41c97f554ec8c71f2a8a5f85cb56a8b0956addfe8b0efb5b3d77e8bdc3/pydantic_core-2.33.2-cp312-cp312-macosx_10_12_x86_64.whl", hash = "sha256:a7ec89dc587667f22b6a0b6579c249fca9026ce7c333fc142ba42411fa243cdc", size = 2009000, upload-time = "2025-04-23T18:31:25.863Z" }, - { url = "https://files.pythonhosted.org/packages/a1/02/6224312aacb3c8ecbaa959897af57181fb6cf3a3d7917fd44d0f2917e6f2/pydantic_core-2.33.2-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:3c6db6e52c6d70aa0d00d45cdb9b40f0433b96380071ea80b09277dba021ddf7", size = 1847996, upload-time = "2025-04-23T18:31:27.341Z" }, - { url = "https://files.pythonhosted.org/packages/d6/46/6dcdf084a523dbe0a0be59d054734b86a981726f221f4562aed313dbcb49/pydantic_core-2.33.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4e61206137cbc65e6d5256e1166f88331d3b6238e082d9f74613b9b765fb9025", size = 1880957, upload-time = "2025-04-23T18:31:28.956Z" }, - { url = "https://files.pythonhosted.org/packages/ec/6b/1ec2c03837ac00886ba8160ce041ce4e325b41d06a034adbef11339ae422/pydantic_core-2.33.2-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:eb8c529b2819c37140eb51b914153063d27ed88e3bdc31b71198a198e921e011", size = 1964199, upload-time = "2025-04-23T18:31:31.025Z" }, - { url = "https://files.pythonhosted.org/packages/2d/1d/6bf34d6adb9debd9136bd197ca72642203ce9aaaa85cfcbfcf20f9696e83/pydantic_core-2.33.2-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c52b02ad8b4e2cf14ca7b3d918f3eb0ee91e63b3167c32591e57c4317e134f8f", size = 2120296, upload-time = "2025-04-23T18:31:32.514Z" }, - { url = "https://files.pythonhosted.org/packages/e0/94/2bd0aaf5a591e974b32a9f7123f16637776c304471a0ab33cf263cf5591a/pydantic_core-2.33.2-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:96081f1605125ba0855dfda83f6f3df5ec90c61195421ba72223de35ccfb2f88", size = 2676109, upload-time = "2025-04-23T18:31:33.958Z" }, - { url = "https://files.pythonhosted.org/packages/f9/41/4b043778cf9c4285d59742281a769eac371b9e47e35f98ad321349cc5d61/pydantic_core-2.33.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8f57a69461af2a5fa6e6bbd7a5f60d3b7e6cebb687f55106933188e79ad155c1", size = 2002028, upload-time = "2025-04-23T18:31:39.095Z" }, - { url = "https://files.pythonhosted.org/packages/cb/d5/7bb781bf2748ce3d03af04d5c969fa1308880e1dca35a9bd94e1a96a922e/pydantic_core-2.33.2-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:572c7e6c8bb4774d2ac88929e3d1f12bc45714ae5ee6d9a788a9fb35e60bb04b", size = 2100044, upload-time = "2025-04-23T18:31:41.034Z" }, - { url = "https://files.pythonhosted.org/packages/fe/36/def5e53e1eb0ad896785702a5bbfd25eed546cdcf4087ad285021a90ed53/pydantic_core-2.33.2-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:db4b41f9bd95fbe5acd76d89920336ba96f03e149097365afe1cb092fceb89a1", size = 2058881, upload-time = "2025-04-23T18:31:42.757Z" }, - { url = "https://files.pythonhosted.org/packages/01/6c/57f8d70b2ee57fc3dc8b9610315949837fa8c11d86927b9bb044f8705419/pydantic_core-2.33.2-cp312-cp312-musllinux_1_1_armv7l.whl", hash = "sha256:fa854f5cf7e33842a892e5c73f45327760bc7bc516339fda888c75ae60edaeb6", size = 2227034, upload-time = "2025-04-23T18:31:44.304Z" }, - { url = "https://files.pythonhosted.org/packages/27/b9/9c17f0396a82b3d5cbea4c24d742083422639e7bb1d5bf600e12cb176a13/pydantic_core-2.33.2-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:5f483cfb75ff703095c59e365360cb73e00185e01aaea067cd19acffd2ab20ea", size = 2234187, upload-time = "2025-04-23T18:31:45.891Z" }, - { url = "https://files.pythonhosted.org/packages/b0/6a/adf5734ffd52bf86d865093ad70b2ce543415e0e356f6cacabbc0d9ad910/pydantic_core-2.33.2-cp312-cp312-win32.whl", hash = "sha256:9cb1da0f5a471435a7bc7e439b8a728e8b61e59784b2af70d7c169f8dd8ae290", size = 1892628, upload-time = "2025-04-23T18:31:47.819Z" }, - { url = "https://files.pythonhosted.org/packages/43/e4/5479fecb3606c1368d496a825d8411e126133c41224c1e7238be58b87d7e/pydantic_core-2.33.2-cp312-cp312-win_amd64.whl", hash = "sha256:f941635f2a3d96b2973e867144fde513665c87f13fe0e193c158ac51bfaaa7b2", size = 1955866, upload-time = "2025-04-23T18:31:49.635Z" }, - { url = "https://files.pythonhosted.org/packages/0d/24/8b11e8b3e2be9dd82df4b11408a67c61bb4dc4f8e11b5b0fc888b38118b5/pydantic_core-2.33.2-cp312-cp312-win_arm64.whl", hash = "sha256:cca3868ddfaccfbc4bfb1d608e2ccaaebe0ae628e1416aeb9c4d88c001bb45ab", size = 1888894, upload-time = "2025-04-23T18:31:51.609Z" }, - { url = "https://files.pythonhosted.org/packages/46/8c/99040727b41f56616573a28771b1bfa08a3d3fe74d3d513f01251f79f172/pydantic_core-2.33.2-cp313-cp313-macosx_10_12_x86_64.whl", hash = "sha256:1082dd3e2d7109ad8b7da48e1d4710c8d06c253cbc4a27c1cff4fbcaa97a9e3f", size = 2015688, upload-time = "2025-04-23T18:31:53.175Z" }, - { url = "https://files.pythonhosted.org/packages/3a/cc/5999d1eb705a6cefc31f0b4a90e9f7fc400539b1a1030529700cc1b51838/pydantic_core-2.33.2-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:f517ca031dfc037a9c07e748cefd8d96235088b83b4f4ba8939105d20fa1dcd6", size = 1844808, upload-time = "2025-04-23T18:31:54.79Z" }, - { url = "https://files.pythonhosted.org/packages/6f/5e/a0a7b8885c98889a18b6e376f344da1ef323d270b44edf8174d6bce4d622/pydantic_core-2.33.2-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0a9f2c9dd19656823cb8250b0724ee9c60a82f3cdf68a080979d13092a3b0fef", size = 1885580, upload-time = "2025-04-23T18:31:57.393Z" }, - { url = "https://files.pythonhosted.org/packages/3b/2a/953581f343c7d11a304581156618c3f592435523dd9d79865903272c256a/pydantic_core-2.33.2-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:2b0a451c263b01acebe51895bfb0e1cc842a5c666efe06cdf13846c7418caa9a", size = 1973859, upload-time = "2025-04-23T18:31:59.065Z" }, - { url = "https://files.pythonhosted.org/packages/e6/55/f1a813904771c03a3f97f676c62cca0c0a4138654107c1b61f19c644868b/pydantic_core-2.33.2-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:1ea40a64d23faa25e62a70ad163571c0b342b8bf66d5fa612ac0dec4f069d916", size = 2120810, upload-time = "2025-04-23T18:32:00.78Z" }, - { url = "https://files.pythonhosted.org/packages/aa/c3/053389835a996e18853ba107a63caae0b9deb4a276c6b472931ea9ae6e48/pydantic_core-2.33.2-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:0fb2d542b4d66f9470e8065c5469ec676978d625a8b7a363f07d9a501a9cb36a", size = 2676498, upload-time = "2025-04-23T18:32:02.418Z" }, - { url = "https://files.pythonhosted.org/packages/eb/3c/f4abd740877a35abade05e437245b192f9d0ffb48bbbbd708df33d3cda37/pydantic_core-2.33.2-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9fdac5d6ffa1b5a83bca06ffe7583f5576555e6c8b3a91fbd25ea7780f825f7d", size = 2000611, upload-time = "2025-04-23T18:32:04.152Z" }, - { url = "https://files.pythonhosted.org/packages/59/a7/63ef2fed1837d1121a894d0ce88439fe3e3b3e48c7543b2a4479eb99c2bd/pydantic_core-2.33.2-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:04a1a413977ab517154eebb2d326da71638271477d6ad87a769102f7c2488c56", size = 2107924, upload-time = "2025-04-23T18:32:06.129Z" }, - { url = "https://files.pythonhosted.org/packages/04/8f/2551964ef045669801675f1cfc3b0d74147f4901c3ffa42be2ddb1f0efc4/pydantic_core-2.33.2-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:c8e7af2f4e0194c22b5b37205bfb293d166a7344a5b0d0eaccebc376546d77d5", size = 2063196, upload-time = "2025-04-23T18:32:08.178Z" }, - { url = "https://files.pythonhosted.org/packages/26/bd/d9602777e77fc6dbb0c7db9ad356e9a985825547dce5ad1d30ee04903918/pydantic_core-2.33.2-cp313-cp313-musllinux_1_1_armv7l.whl", hash = "sha256:5c92edd15cd58b3c2d34873597a1e20f13094f59cf88068adb18947df5455b4e", size = 2236389, upload-time = "2025-04-23T18:32:10.242Z" }, - { url = "https://files.pythonhosted.org/packages/42/db/0e950daa7e2230423ab342ae918a794964b053bec24ba8af013fc7c94846/pydantic_core-2.33.2-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:65132b7b4a1c0beded5e057324b7e16e10910c106d43675d9bd87d4f38dde162", size = 2239223, upload-time = "2025-04-23T18:32:12.382Z" }, - { url = "https://files.pythonhosted.org/packages/58/4d/4f937099c545a8a17eb52cb67fe0447fd9a373b348ccfa9a87f141eeb00f/pydantic_core-2.33.2-cp313-cp313-win32.whl", hash = "sha256:52fb90784e0a242bb96ec53f42196a17278855b0f31ac7c3cc6f5c1ec4811849", size = 1900473, upload-time = "2025-04-23T18:32:14.034Z" }, - { url = "https://files.pythonhosted.org/packages/a0/75/4a0a9bac998d78d889def5e4ef2b065acba8cae8c93696906c3a91f310ca/pydantic_core-2.33.2-cp313-cp313-win_amd64.whl", hash = "sha256:c083a3bdd5a93dfe480f1125926afcdbf2917ae714bdb80b36d34318b2bec5d9", size = 1955269, upload-time = "2025-04-23T18:32:15.783Z" }, - { url = "https://files.pythonhosted.org/packages/f9/86/1beda0576969592f1497b4ce8e7bc8cbdf614c352426271b1b10d5f0aa64/pydantic_core-2.33.2-cp313-cp313-win_arm64.whl", hash = "sha256:e80b087132752f6b3d714f041ccf74403799d3b23a72722ea2e6ba2e892555b9", size = 1893921, upload-time = "2025-04-23T18:32:18.473Z" }, - { url = "https://files.pythonhosted.org/packages/a4/7d/e09391c2eebeab681df2b74bfe6c43422fffede8dc74187b2b0bf6fd7571/pydantic_core-2.33.2-cp313-cp313t-macosx_11_0_arm64.whl", hash = "sha256:61c18fba8e5e9db3ab908620af374db0ac1baa69f0f32df4f61ae23f15e586ac", size = 1806162, upload-time = "2025-04-23T18:32:20.188Z" }, - { url = "https://files.pythonhosted.org/packages/f1/3d/847b6b1fed9f8ed3bb95a9ad04fbd0b212e832d4f0f50ff4d9ee5a9f15cf/pydantic_core-2.33.2-cp313-cp313t-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:95237e53bb015f67b63c91af7518a62a8660376a6a0db19b89acc77a4d6199f5", size = 1981560, upload-time = "2025-04-23T18:32:22.354Z" }, - { url = "https://files.pythonhosted.org/packages/6f/9a/e73262f6c6656262b5fdd723ad90f518f579b7bc8622e43a942eec53c938/pydantic_core-2.33.2-cp313-cp313t-win_amd64.whl", hash = "sha256:c2fc0a768ef76c15ab9238afa6da7f69895bb5d1ee83aeea2e3509af4472d0b9", size = 1935777, upload-time = "2025-04-23T18:32:25.088Z" }, - { url = "https://files.pythonhosted.org/packages/30/68/373d55e58b7e83ce371691f6eaa7175e3a24b956c44628eb25d7da007917/pydantic_core-2.33.2-pp310-pypy310_pp73-macosx_10_12_x86_64.whl", hash = "sha256:5c4aa4e82353f65e548c476b37e64189783aa5384903bfea4f41580f255fddfa", size = 2023982, upload-time = "2025-04-23T18:32:53.14Z" }, - { url = "https://files.pythonhosted.org/packages/a4/16/145f54ac08c96a63d8ed6442f9dec17b2773d19920b627b18d4f10a061ea/pydantic_core-2.33.2-pp310-pypy310_pp73-macosx_11_0_arm64.whl", hash = "sha256:d946c8bf0d5c24bf4fe333af284c59a19358aa3ec18cb3dc4370080da1e8ad29", size = 1858412, upload-time = "2025-04-23T18:32:55.52Z" }, - { url = "https://files.pythonhosted.org/packages/41/b1/c6dc6c3e2de4516c0bb2c46f6a373b91b5660312342a0cf5826e38ad82fa/pydantic_core-2.33.2-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:87b31b6846e361ef83fedb187bb5b4372d0da3f7e28d85415efa92d6125d6e6d", size = 1892749, upload-time = "2025-04-23T18:32:57.546Z" }, - { url = "https://files.pythonhosted.org/packages/12/73/8cd57e20afba760b21b742106f9dbdfa6697f1570b189c7457a1af4cd8a0/pydantic_core-2.33.2-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:aa9d91b338f2df0508606f7009fde642391425189bba6d8c653afd80fd6bb64e", size = 2067527, upload-time = "2025-04-23T18:32:59.771Z" }, - { url = "https://files.pythonhosted.org/packages/e3/d5/0bb5d988cc019b3cba4a78f2d4b3854427fc47ee8ec8e9eaabf787da239c/pydantic_core-2.33.2-pp310-pypy310_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:2058a32994f1fde4ca0480ab9d1e75a0e8c87c22b53a3ae66554f9af78f2fe8c", size = 2108225, upload-time = "2025-04-23T18:33:04.51Z" }, - { url = "https://files.pythonhosted.org/packages/f1/c5/00c02d1571913d496aabf146106ad8239dc132485ee22efe08085084ff7c/pydantic_core-2.33.2-pp310-pypy310_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:0e03262ab796d986f978f79c943fc5f620381be7287148b8010b4097f79a39ec", size = 2069490, upload-time = "2025-04-23T18:33:06.391Z" }, - { url = "https://files.pythonhosted.org/packages/22/a8/dccc38768274d3ed3a59b5d06f59ccb845778687652daa71df0cab4040d7/pydantic_core-2.33.2-pp310-pypy310_pp73-musllinux_1_1_armv7l.whl", hash = "sha256:1a8695a8d00c73e50bff9dfda4d540b7dee29ff9b8053e38380426a85ef10052", size = 2237525, upload-time = "2025-04-23T18:33:08.44Z" }, - { url = "https://files.pythonhosted.org/packages/d4/e7/4f98c0b125dda7cf7ccd14ba936218397b44f50a56dd8c16a3091df116c3/pydantic_core-2.33.2-pp310-pypy310_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:fa754d1850735a0b0e03bcffd9d4b4343eb417e47196e4485d9cca326073a42c", size = 2238446, upload-time = "2025-04-23T18:33:10.313Z" }, - { url = "https://files.pythonhosted.org/packages/ce/91/2ec36480fdb0b783cd9ef6795753c1dea13882f2e68e73bce76ae8c21e6a/pydantic_core-2.33.2-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:a11c8d26a50bfab49002947d3d237abe4d9e4b5bdc8846a63537b6488e197808", size = 2066678, upload-time = "2025-04-23T18:33:12.224Z" }, - { url = "https://files.pythonhosted.org/packages/7b/27/d4ae6487d73948d6f20dddcd94be4ea43e74349b56eba82e9bdee2d7494c/pydantic_core-2.33.2-pp311-pypy311_pp73-macosx_10_12_x86_64.whl", hash = "sha256:dd14041875d09cc0f9308e37a6f8b65f5585cf2598a53aa0123df8b129d481f8", size = 2025200, upload-time = "2025-04-23T18:33:14.199Z" }, - { url = "https://files.pythonhosted.org/packages/f1/b8/b3cb95375f05d33801024079b9392a5ab45267a63400bf1866e7ce0f0de4/pydantic_core-2.33.2-pp311-pypy311_pp73-macosx_11_0_arm64.whl", hash = "sha256:d87c561733f66531dced0da6e864f44ebf89a8fba55f31407b00c2f7f9449593", size = 1859123, upload-time = "2025-04-23T18:33:16.555Z" }, - { url = "https://files.pythonhosted.org/packages/05/bc/0d0b5adeda59a261cd30a1235a445bf55c7e46ae44aea28f7bd6ed46e091/pydantic_core-2.33.2-pp311-pypy311_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2f82865531efd18d6e07a04a17331af02cb7a651583c418df8266f17a63c6612", size = 1892852, upload-time = "2025-04-23T18:33:18.513Z" }, - { url = "https://files.pythonhosted.org/packages/3e/11/d37bdebbda2e449cb3f519f6ce950927b56d62f0b84fd9cb9e372a26a3d5/pydantic_core-2.33.2-pp311-pypy311_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2bfb5112df54209d820d7bf9317c7a6c9025ea52e49f46b6a2060104bba37de7", size = 2067484, upload-time = "2025-04-23T18:33:20.475Z" }, - { url = "https://files.pythonhosted.org/packages/8c/55/1f95f0a05ce72ecb02a8a8a1c3be0579bbc29b1d5ab68f1378b7bebc5057/pydantic_core-2.33.2-pp311-pypy311_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:64632ff9d614e5eecfb495796ad51b0ed98c453e447a76bcbeeb69615079fc7e", size = 2108896, upload-time = "2025-04-23T18:33:22.501Z" }, - { url = "https://files.pythonhosted.org/packages/53/89/2b2de6c81fa131f423246a9109d7b2a375e83968ad0800d6e57d0574629b/pydantic_core-2.33.2-pp311-pypy311_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:f889f7a40498cc077332c7ab6b4608d296d852182211787d4f3ee377aaae66e8", size = 2069475, upload-time = "2025-04-23T18:33:24.528Z" }, - { url = "https://files.pythonhosted.org/packages/b8/e9/1f7efbe20d0b2b10f6718944b5d8ece9152390904f29a78e68d4e7961159/pydantic_core-2.33.2-pp311-pypy311_pp73-musllinux_1_1_armv7l.whl", hash = "sha256:de4b83bb311557e439b9e186f733f6c645b9417c84e2eb8203f3f820a4b988bf", size = 2239013, upload-time = "2025-04-23T18:33:26.621Z" }, - { url = "https://files.pythonhosted.org/packages/3c/b2/5309c905a93811524a49b4e031e9851a6b00ff0fb668794472ea7746b448/pydantic_core-2.33.2-pp311-pypy311_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:82f68293f055f51b51ea42fafc74b6aad03e70e191799430b90c13d643059ebb", size = 2238715, upload-time = "2025-04-23T18:33:28.656Z" }, - { url = "https://files.pythonhosted.org/packages/32/56/8a7ca5d2cd2cda1d245d34b1c9a942920a718082ae8e54e5f3e5a58b7add/pydantic_core-2.33.2-pp311-pypy311_pp73-win_amd64.whl", hash = "sha256:329467cecfb529c925cf2bbd4d60d2c509bc2fb52a20c1045bf09bb70971a9c1", size = 2066757, upload-time = "2025-04-23T18:33:30.645Z" }, +sdist = { url = "https://files.pythonhosted.org/packages/af/f9/8a06bea35ef8daf588f707784c973a7046e0034c8d8cfb08828eeffb8b75/pydantic_core-2.46.5.tar.gz", hash = "sha256:10416c15b8839ecc4ef4d0885da76da6fd0f67333a0eb8aff6d93c4b8f2910fc", size = 472262, upload-time = "2026-08-28T10:01:31.677Z" } +wheels = [ + { url = "https://files.pythonhosted.org/packages/74/6b/8f79692844269427abb3e4dd9e68edfcbe65ae25527d99183214de716c59/pydantic_core-2.46.5-cp310-cp310-macosx_10_12_x86_64.whl", hash = "sha256:657b40d6240c0a7b6a64b30f22d1e3aa631c7e846c621b0c0f6d1d75e2e15ea6", size = 2076533, upload-time = "2026-08-28T09:57:35.421Z" }, + { url = "https://files.pythonhosted.org/packages/bd/d0/c787604c71c2bdcda1a5656942fc822cd0f9cd879b9484bb84fc42172703/pydantic_core-2.46.5-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:ecb42011e12ee19cafbc312887cbf3546959fe02fbad44f272d4be5baa997615", size = 1924650, upload-time = "2026-08-28T09:57:37.944Z" }, + { url = "https://files.pythonhosted.org/packages/4a/77/ca2f8e997d9bfdb32205297aff38f210f398822d895b1af1b59fd9df9c13/pydantic_core-2.46.5-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4dedce55295becb61921e386b99d4f2706045306e7fa52249a33004c837379fb", size = 1951261, upload-time = "2026-08-28T09:57:39.339Z" }, + { url = "https://files.pythonhosted.org/packages/a0/53/bd12e1a9255df4edee00353778e2614b5346265d51e1567ab72153e803a2/pydantic_core-2.46.5-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:9f47b8a949e60f027f0aa0a6f6c7b7e9c55cbf4380d10b344e282fa4e7ab1e1b", size = 2021808, upload-time = "2026-08-28T09:57:40.69Z" }, + { url = "https://files.pythonhosted.org/packages/d7/41/f7f312751ebc6d6767da91964a9c7954c18e226a1720ab234e3dfb9d6c17/pydantic_core-2.46.5-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:200aa3dc9f8d54f0754f43247c0bad0999fdcfbfd2488384dd44f37279271fe6", size = 2196184, upload-time = "2026-08-28T09:57:42.275Z" }, + { url = "https://files.pythonhosted.org/packages/3d/93/ce93aa030ab6bac4683ba8861e7baad89dd24b02e66b8801a0e4f6a00311/pydantic_core-2.46.5-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:6d30e1a4f138b8951063e9a394752a9179b51da288ffa507b1e659222f4c1793", size = 2238212, upload-time = "2026-08-28T09:57:44.122Z" }, + { url = "https://files.pythonhosted.org/packages/34/a1/c8e6b66f499f510752c07a092dfe27621f9c255635e59d38704b5681c35a/pydantic_core-2.46.5-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:850a08d167dde16db8702c274f320c7be9d7da6f6dff2b58b18f9e815bd94f5b", size = 2064073, upload-time = "2026-08-28T09:57:45.613Z" }, + { url = "https://files.pythonhosted.org/packages/5c/fa/605e2b127ee30dbf4b1da9da4843587cf2b2d16486c241cc7a5be2d2c1bd/pydantic_core-2.46.5-cp310-cp310-manylinux_2_31_riscv64.whl", hash = "sha256:c3471e5c4a949c26ec00a77f01df59096aa9495877de76fd60a980f8ee6be461", size = 2093102, upload-time = "2026-08-28T09:57:46.953Z" }, + { url = "https://files.pythonhosted.org/packages/4a/f7/1ab28093c09032ddce7c92c7a55d503b6ecd70f42c32492946c1cb5477b1/pydantic_core-2.46.5-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:3a3e26b6a8274211bddee2d0e4d0d42778f17a34510f49d2ec44b58abfc41736", size = 2133452, upload-time = "2026-08-28T09:57:48.362Z" }, + { url = "https://files.pythonhosted.org/packages/30/c8/47c79b756f12f85e8b0fbdb2b495f6b6eb32e6c98a4beae7a570a0b7c63c/pydantic_core-2.46.5-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:fc5d783bd4a2387e97b8a2d5ec781cfb92b3d893bf82370548e99db5915935d3", size = 2146477, upload-time = "2026-08-28T09:57:49.74Z" }, + { url = "https://files.pythonhosted.org/packages/13/5c/79fc00cb8f651d6061991de8d7cedf1c78c73cbd4862c42ef418f03b8bfa/pydantic_core-2.46.5-cp310-cp310-musllinux_1_1_armv7l.whl", hash = "sha256:356c8368cbc321050b169595683a2e1d63413b1e0e2868b330af9fc14c616d3f", size = 2300832, upload-time = "2026-08-28T09:57:51.639Z" }, + { url = "https://files.pythonhosted.org/packages/b4/72/dd1a29853cf6d22a1ebd9e3baf0239cbc57d2d16caff36a89e38eb9b1db3/pydantic_core-2.46.5-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:eb7d8d0e5886a89a55d2eef490e272fa965a9d57c6b29a5b5088a7997ec2cad1", size = 2320505, upload-time = "2026-08-28T09:57:53.236Z" }, + { url = "https://files.pythonhosted.org/packages/ec/d1/ba4a8e06a9ddad0b4caf69cfaeecc0fbfcec20473bd808f5127fd16491c4/pydantic_core-2.46.5-cp310-cp310-win32.whl", hash = "sha256:4d44cf99ddebf875f9b68cc267aa684c99b7b44fe63ee1cac4ec163807290069", size = 1956853, upload-time = "2026-08-28T09:57:54.592Z" }, + { url = "https://files.pythonhosted.org/packages/f2/94/205ed9d7ddaf44acd489889708ea124a3f41bdb42c141c8684d528ad0e7a/pydantic_core-2.46.5-cp310-cp310-win_amd64.whl", hash = "sha256:1e5aad1220a1192c42341c8fd4a8686657e73ab2a920c970bdc4de334fe3193d", size = 2042551, upload-time = "2026-08-28T09:57:56.017Z" }, + { url = "https://files.pythonhosted.org/packages/a2/b6/81d2d19ea0be2c03664381b59f65fa72fc7969decedae00bc2c4ad835708/pydantic_core-2.46.5-cp311-cp311-macosx_10_12_x86_64.whl", hash = "sha256:a1dee1b804ff4d11c663636cf15d2ea47e9f79cd56c033fb1cbf08924842a48f", size = 2074737, upload-time = "2026-08-28T09:57:57.711Z" }, + { url = "https://files.pythonhosted.org/packages/0c/18/b70da8300e292df4099684ea11b1958043580d2f50d2dc8bf7e542bdd84a/pydantic_core-2.46.5-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:d625a186a65201c23a9e3b8ed9c47e90a026e03256608cc91851c6709096844f", size = 1921751, upload-time = "2026-08-28T09:57:59.265Z" }, + { url = "https://files.pythonhosted.org/packages/e7/1a/0d590341b6ffa4b4aca83508e6b8db4761aaeacfc15a25ca3815876d4797/pydantic_core-2.46.5-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4f8507560a9284e1370bb048ed4282012fbef4e8d109875b95e884d228552061", size = 1948231, upload-time = "2026-08-28T09:58:00.678Z" }, + { url = "https://files.pythonhosted.org/packages/7d/1d/02eb35761c51f2f7b1b042d6ab4cda6600f0c8c88a2243b3f734376201e5/pydantic_core-2.46.5-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:5f93c5fe914d75fbec9a49209b00da5f08e9e467d69da2b1510c81940cfd10be", size = 2020708, upload-time = "2026-08-28T09:58:02.267Z" }, + { url = "https://files.pythonhosted.org/packages/4a/ea/f86073830e35d508cc8ddf9c3d9e6e6840fcb88d34bf726b0b4710186f27/pydantic_core-2.46.5-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:aca6c767f552b21b10f774aeac128e828eafb796adfa1b666a18bf6321453c3a", size = 2194914, upload-time = "2026-08-28T09:58:03.934Z" }, + { url = "https://files.pythonhosted.org/packages/bb/d7/fc36240d7791ce90939e51608568c33bfdae26202016f9770c229a487d86/pydantic_core-2.46.5-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:701b2e04b560eeb4bddf7a25ab8ca476176e34fdbd9a0e18196f0d12d4685f0b", size = 2235622, upload-time = "2026-08-28T09:58:05.516Z" }, + { url = "https://files.pythonhosted.org/packages/cf/bc/3fa2d76b83162820a17da7f645b28d1cba99fc8e1e5fc6517067ec450fa1/pydantic_core-2.46.5-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:49776eab08766a08dfff7012f8b422dcd7e25e43b316eedf0477c24fcfa84b7c", size = 2062091, upload-time = "2026-08-28T09:58:07.135Z" }, + { url = "https://files.pythonhosted.org/packages/ab/9a/095d557bb492c90cd8a70a6dd048bf793d433d03d86c81c11e912e4cd049/pydantic_core-2.46.5-cp311-cp311-manylinux_2_31_riscv64.whl", hash = "sha256:a2468d93d181667a7abd66e1b64bb9f76f361b0fef8faddf687456453576f5ee", size = 2089904, upload-time = "2026-08-28T09:58:08.814Z" }, + { url = "https://files.pythonhosted.org/packages/24/98/7b76b1ad10a19a617a52aaa1d80e159115af939b095e86f8e756fd52e0df/pydantic_core-2.46.5-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:53feb344243bb9510a9dec7bf3cf1b64d88a98af5dc7872a5160465f8b198c8e", size = 2132244, upload-time = "2026-08-28T09:58:10.435Z" }, + { url = "https://files.pythonhosted.org/packages/20/32/7d6ca365fadba186a0c8f85de1a701663bce81efd309d9479be58687622f/pydantic_core-2.46.5-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:cd5214352ae68f3b5e9af7768bdc5253695ee069675db3480518420b3be881f2", size = 2143901, upload-time = "2026-08-28T09:58:12.033Z" }, + { url = "https://files.pythonhosted.org/packages/f8/09/eb9a6aa57f22fd1541a9c0aa2a1f3aeef3ec65347d33e10a6da2f43e0ee9/pydantic_core-2.46.5-cp311-cp311-musllinux_1_1_armv7l.whl", hash = "sha256:9432f3598db432cb51c5b37fdbf29a60fcccc79e30d37a05022776a6bc4ab689", size = 2299425, upload-time = "2026-08-28T09:58:13.614Z" }, + { url = "https://files.pythonhosted.org/packages/8a/f9/548a5bb9d4ba8cd26e26daf48052236f6b38bb61e7b7241fbc3c995719eb/pydantic_core-2.46.5-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:8feeac04b5794e513e710af2f9c87d49f31a6dc47967bb264a1fed61a8989bec", size = 2318566, upload-time = "2026-08-28T09:58:15.199Z" }, + { url = "https://files.pythonhosted.org/packages/4a/20/06454d18834c02c406c9133f1a3b485305fd9ee984f9636c2f730bef6a9d/pydantic_core-2.46.5-cp311-cp311-win32.whl", hash = "sha256:892a881d5f68c2b9ea304b7a6c2c60d9343df578a311b0f86b94bc8f1ffe8129", size = 1954258, upload-time = "2026-08-28T09:58:16.813Z" }, + { url = "https://files.pythonhosted.org/packages/9e/c2/718b9deb4b72453b5d8c7447a3b14cb77bef36917ef5f514e0948a4096a0/pydantic_core-2.46.5-cp311-cp311-win_amd64.whl", hash = "sha256:40375c2d05acec10323e45dfe2077ac44bc74659008614af5069034e2cfc781c", size = 2041030, upload-time = "2026-08-28T09:58:18.288Z" }, + { url = "https://files.pythonhosted.org/packages/67/ea/c1d1a5b72d6e1ff7f377a4d9199f6591f095beb5b409a8a5d89f7238d939/pydantic_core-2.46.5-cp311-cp311-win_arm64.whl", hash = "sha256:28a6a556cd3b6066bea827857f9d9cce027c96f776e512f544a581f9e42161f8", size = 2009234, upload-time = "2026-08-28T09:58:19.929Z" }, + { url = "https://files.pythonhosted.org/packages/82/3f/76358795aa7a8c6d4f36e2cb828ad1c90ee118e1393a9281664f5aade9d4/pydantic_core-2.46.5-cp312-cp312-macosx_10_12_x86_64.whl", hash = "sha256:b9fe6fb92520e3fd61f2e49000b6911b188824f089b75973ea06d6267f0b476d", size = 2076516, upload-time = "2026-08-28T09:58:21.576Z" }, + { url = "https://files.pythonhosted.org/packages/db/50/26b091836076ce4cb2fac264186936acc069e0595772cfd02a563bc4761a/pydantic_core-2.46.5-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:a39ac25a9a2fa4072efdb429833c4a4c8009a51ff9eea3eeae131713cd27991e", size = 1922874, upload-time = "2026-08-28T09:58:23.766Z" }, + { url = "https://files.pythonhosted.org/packages/09/f0/2a8ce3849e299d44e2d2c196b6082643a3235565a735cb51db7a6261f614/pydantic_core-2.46.5-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4fdc8b93a41521988916eeaa271173fcca7fa0803d62f87675aac8dcec1c8e29", size = 1951772, upload-time = "2026-08-28T09:58:25.435Z" }, + { url = "https://files.pythonhosted.org/packages/87/46/ac0dc8bdd9e6048183a14eb127764e7ad9240021c17513074a4711b0e31e/pydantic_core-2.46.5-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:b98134087d9de723658d17a42c7d0da8d6e2ef08015dee7dc93889047315f5e4", size = 2031832, upload-time = "2026-08-28T09:58:27.102Z" }, + { url = "https://files.pythonhosted.org/packages/c4/c2/339de5bef7be36301a2231eaa52e62163742c2281f11b5f4892bc79785cd/pydantic_core-2.46.5-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:e652ab17569c94bff5475520f907b7148b8c24036a8ebbe5cf7cf7493d28579a", size = 2208645, upload-time = "2026-08-28T09:58:28.948Z" }, + { url = "https://files.pythonhosted.org/packages/7b/a0/9ff22b797724262da14427abaed4dd1d864a139693fc5e7809114376a716/pydantic_core-2.46.5-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:d925f3d9afd05a8c0fb3a1031463a8d59ebe5e2afad297e29c78be19e13b4e62", size = 2265935, upload-time = "2026-08-28T09:58:30.625Z" }, + { url = "https://files.pythonhosted.org/packages/c0/a4/eb9409ec0736e50aa70a412f16c204ed149516846912f7e6724d4c73ee53/pydantic_core-2.46.5-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:0fc5be0abd4a407e200d844b404e33639a554e7bd0d448e7b9ae181be4789ac2", size = 2066284, upload-time = "2026-08-28T09:58:32.289Z" }, + { url = "https://files.pythonhosted.org/packages/c0/02/7f6156ffc926857f1c37c07d9a388682865a81830ab6a1b637082c25e399/pydantic_core-2.46.5-cp312-cp312-manylinux_2_31_riscv64.whl", hash = "sha256:816ff0a6550ffc06c098ccd2e0698600f9aa7da192a79eaa6f9af504a35db869", size = 2105889, upload-time = "2026-08-28T09:58:33.986Z" }, + { url = "https://files.pythonhosted.org/packages/92/b1/e781d357ebe09fc929f995700f1b3503e8897f1cece183ecb1300d4d67e9/pydantic_core-2.46.5-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:c7ea57fc63aa7da93a1bd2d644e6577befae10c52c4e36377635eea1056a74f5", size = 2158006, upload-time = "2026-08-28T09:58:35.647Z" }, + { url = "https://files.pythonhosted.org/packages/70/0a/644597d84ab400e50609c192120b85c9681c22d3a20461b9060a79be0a7a/pydantic_core-2.46.5-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:efd62a42486f1bda5d24cb4f63d15a3c7768375fe83d36f9417b4ad7a2fb20b3", size = 2158408, upload-time = "2026-08-28T09:58:37.38Z" }, + { url = "https://files.pythonhosted.org/packages/1e/ee/ca3b7b3a4b3769ffe9ce9432a7c9be755de9593a46d3b0d54d0409323e44/pydantic_core-2.46.5-cp312-cp312-musllinux_1_1_armv7l.whl", hash = "sha256:2bc9419666990c06d7397831f2126a1ecc3594aaa3ff7de5bf2d066802f4e07b", size = 2309609, upload-time = "2026-08-28T09:58:39.22Z" }, + { url = "https://files.pythonhosted.org/packages/ce/52/39fa1f451486019524ca685020390e7ca351832fd874530ba30c8628e6dc/pydantic_core-2.46.5-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:18a09e1e1011b462f2e32774f25859ef1223d5c2b0546a633cf56654710721e0", size = 2342618, upload-time = "2026-08-28T09:58:40.89Z" }, + { url = "https://files.pythonhosted.org/packages/81/5e/468fc630568c61dcef3cd47ad32ffbeed9af643f49208d1ea86ab4f890c4/pydantic_core-2.46.5-cp312-cp312-win32.whl", hash = "sha256:5cb482e9e84c851f4e623fe4acc1ced89168cf1fe18f7089db4548c8f5bbb65b", size = 1939475, upload-time = "2026-08-28T09:58:42.591Z" }, + { url = "https://files.pythonhosted.org/packages/cf/c9/4c19f41b84cf6b622a72fbeed7665b25d47a187d68d47d0d430c07f23268/pydantic_core-2.46.5-cp312-cp312-win_amd64.whl", hash = "sha256:5e81740c09e310f5aa5cbd3e434a01c154d4bef93241c7877b39f211d2b78ba8", size = 2043140, upload-time = "2026-08-28T09:58:44.272Z" }, + { url = "https://files.pythonhosted.org/packages/af/dd/0c1a050299147c746e5256db16d645ab5efd4f78c59937d581a0524e74a2/pydantic_core-2.46.5-cp312-cp312-win_arm64.whl", hash = "sha256:f7b0ec93a2893de856652154d73b7ba622f26fa97726487dcac373de5f4c6084", size = 1997729, upload-time = "2026-08-28T09:58:46.13Z" }, + { url = "https://files.pythonhosted.org/packages/f5/37/5abe39a8372a61d3dc3c1338fc504281c01b32fdb3169cd7187153b56d3e/pydantic_core-2.46.5-cp313-cp313-macosx_10_12_x86_64.whl", hash = "sha256:b7ca9034437b6022f941f4857459562ee00a560b97e7cce8a0ec5a74fc6766e0", size = 2075885, upload-time = "2026-08-28T09:58:47.856Z" }, + { url = "https://files.pythonhosted.org/packages/21/43/6323b1f8b217780454c61304bcd2b38ae4762f50754414124603ccc90bb2/pydantic_core-2.46.5-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:f332f0e72a5a0400141f830744e141bf9f97917878dbe968669e8a7fefea78ff", size = 1922768, upload-time = "2026-08-28T09:58:49.58Z" }, + { url = "https://files.pythonhosted.org/packages/0f/a3/c05ca796e1197618a774b01e596aeedfefc2f7d8c01ae3054e910b120e8a/pydantic_core-2.46.5-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:193375f3548919d3f0b60936ca113ada3e38f264f91b9b8e0508efaad57be931", size = 1951241, upload-time = "2026-08-28T09:58:51.511Z" }, + { url = "https://files.pythonhosted.org/packages/68/32/33bc39ac705c52cffc908e8389f9754fdb208aea5c69cceddf4eb3ce99af/pydantic_core-2.46.5-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:79bdfa52f843137045b2d081cc05c120ba6665d29b7559c2c47690906f39279f", size = 2031975, upload-time = "2026-08-28T09:58:53.166Z" }, + { url = "https://files.pythonhosted.org/packages/b0/70/2333e885c0f6a67bc105c5916965dac9b57f2718ee20d81d1a06a4ebdc13/pydantic_core-2.46.5-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:24922243639cbdac66c75fcb6fd6495a9cb52b213d62f9a0d16f0310b1ff8038", size = 2208542, upload-time = "2026-08-28T09:58:55.017Z" }, + { url = "https://files.pythonhosted.org/packages/f7/ea/296debfb4264207bbda5936133892e027c0a58875ad53ebd512fba8ec3a2/pydantic_core-2.46.5-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:c76fe65e607be28c7fd4d56fc3c42b1583aa058ce3408b7ad0fd540171d31f9f", size = 2264692, upload-time = "2026-08-28T09:58:56.767Z" }, + { url = "https://files.pythonhosted.org/packages/d3/f2/9e4de77a6271e07a76d2d58b11c091a979c191ed2939bf80067568b369d2/pydantic_core-2.46.5-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6f7b393a8b3da82f5c1fc0751e6d01ac6c55b93c18226a60bdfba4a724efafd1", size = 2066633, upload-time = "2026-08-28T09:58:58.531Z" }, + { url = "https://files.pythonhosted.org/packages/8d/db/f9e9d0c97445987b2084823d5c240de88087338f04fc2cfaa2df186b8049/pydantic_core-2.46.5-cp313-cp313-manylinux_2_31_riscv64.whl", hash = "sha256:7ac031912d54f3d83ef3b3eb98dfabc1608802e2202263d25957eeed40b94761", size = 2105235, upload-time = "2026-08-28T09:59:00.421Z" }, + { url = "https://files.pythonhosted.org/packages/07/c5/79169b047b3b2c3e99e04bc76372af9637e0bf6db638274fa927df96369e/pydantic_core-2.46.5-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:837b396ca3d7b74091ca623f6cbd8351bd42d670a79c2683e79fb089f06a2de5", size = 2157367, upload-time = "2026-08-28T09:59:02.442Z" }, + { url = "https://files.pythonhosted.org/packages/26/b5/ba6057afb7c291bd449f51b867f95aef2072941c4ce4e5c31d6ffd132d3b/pydantic_core-2.46.5-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:5ee239d575f80b08eca11f6e20f90c4c695de7825c67eefe6091fbf20dda648e", size = 2158420, upload-time = "2026-08-28T09:59:04.2Z" }, + { url = "https://files.pythonhosted.org/packages/6e/28/2057abecaafdc22912afa819603a51f0a62d40643b7c4871c51721fea9be/pydantic_core-2.46.5-cp313-cp313-musllinux_1_1_armv7l.whl", hash = "sha256:e80675d75ae2cd14372cb65cad5400d9347a3d3f6c13000183f22dfd027283ed", size = 2309588, upload-time = "2026-08-28T09:59:06.048Z" }, + { url = "https://files.pythonhosted.org/packages/71/9d/881156dc404e27479c4246128d73538464cab4a239bec61995e227644c30/pydantic_core-2.46.5-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:9c4b71f10dd532fb7a5cbc8f58707779e64f03a258c2bf8bfbaecfcd9970b519", size = 2341866, upload-time = "2026-08-28T09:59:08.539Z" }, + { url = "https://files.pythonhosted.org/packages/5a/38/d66f443a259f84d13babdceae568e572b0ed26da17ca5d0a649ebb110a67/pydantic_core-2.46.5-cp313-cp313-win32.whl", hash = "sha256:97bf8de4d541598c94a59344eeb988a94c08ff76b5723c41f6567ec18c7892ea", size = 1938580, upload-time = "2026-08-28T09:59:10.402Z" }, + { url = "https://files.pythonhosted.org/packages/2c/1e/1d5371213f4cc9a7ed70c0bfcc7911de22311ee99a662a56077d7292d2ac/pydantic_core-2.46.5-cp313-cp313-win_amd64.whl", hash = "sha256:15f4a94963c95accac15b7b657bb177d3ad82bb90b0d0526d9a9b85079925db5", size = 2041980, upload-time = "2026-08-28T09:59:12.396Z" }, + { url = "https://files.pythonhosted.org/packages/5a/48/4222d90b1c67568bace4dec6dca6271449c66de3595d72b6d098f5fde597/pydantic_core-2.46.5-cp313-cp313-win_arm64.whl", hash = "sha256:d22a945598fb91236b4dd793a6e42e4f3dd7740bb5aace5ebd7d4c08d13bb575", size = 1997213, upload-time = "2026-08-28T09:59:14.245Z" }, + { url = "https://files.pythonhosted.org/packages/af/1e/ecca01fce348f7e8afa9572441ff6f7d1cc70d21e4859f33944d10877e1e/pydantic_core-2.46.5-graalpy311-graalpy242_311_native-macosx_10_12_x86_64.whl", hash = "sha256:c14ad3bdc85ee7f318742c457ca3968a92126d144b15721c759033bfb06296c2", size = 2075342, upload-time = "2026-08-28T10:00:51.353Z" }, + { url = "https://files.pythonhosted.org/packages/1f/4c/af80c7a8032dfc897040ad5cb772bebde529a381186499e6e29987f23f8c/pydantic_core-2.46.5-graalpy311-graalpy242_311_native-macosx_11_0_arm64.whl", hash = "sha256:0bddb4020d8f04175865ccd17eff3040874fc11fb593f424edb452653b4b947c", size = 1907219, upload-time = "2026-08-28T10:00:53.438Z" }, + { url = "https://files.pythonhosted.org/packages/be/3e/54d89e2b092e778716bf6153634ef479e955f48c261090be23aa1e0fb0b5/pydantic_core-2.46.5-graalpy311-graalpy242_311_native-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2471fd51c61c610e1dcf7de44d7299283661654d11264ab4802b303368d69c47", size = 1953393, upload-time = "2026-08-28T10:00:55.58Z" }, + { url = "https://files.pythonhosted.org/packages/ea/89/828ee90cda28ce17bdefaa3a6eaf74fe430e113295a10e6126beca559d6c/pydantic_core-2.46.5-graalpy311-graalpy242_311_native-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b10ec717381bdbfafef34607824db4c91de69ff085e4fca3b2af91b4fa17e68a", size = 2099024, upload-time = "2026-08-28T10:00:57.794Z" }, + { url = "https://files.pythonhosted.org/packages/df/dd/053c2e4303f791f3b8f8a14ab0b22008e8eb21d868c0c90b4f9be705b76a/pydantic_core-2.46.5-graalpy312-graalpy250_312_native-macosx_10_12_x86_64.whl", hash = "sha256:013d6f3483d81e02e7c328831808f336c8596ee33b4bd4026b9ffb1e960b8942", size = 2062540, upload-time = "2026-08-28T10:01:00.318Z" }, + { url = "https://files.pythonhosted.org/packages/d7/dd/a18df751a5e37dd51bfad7f68e766999125bebe68c9e1d10a493ad01bd63/pydantic_core-2.46.5-graalpy312-graalpy250_312_native-macosx_11_0_arm64.whl", hash = "sha256:e9c134bb666dd54b778b9fc0d2b50cbb7f979b9e3716f26a88c9ab3b6fc1dd0f", size = 1902040, upload-time = "2026-08-28T10:01:02.529Z" }, + { url = "https://files.pythonhosted.org/packages/b7/13/01d40f9d07ce8a779fd6e0bd8ad4fba91309500dd67b869e2e219d261a6d/pydantic_core-2.46.5-graalpy312-graalpy250_312_native-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:347ec774390c87326a2e4929d58d3f7e8763a104d5d35f4cd595a4c952366433", size = 1967479, upload-time = "2026-08-28T10:01:05.004Z" }, + { url = "https://files.pythonhosted.org/packages/fa/04/c81d4841331c2178b6fb09ae225425e110ed72d990c9fe556c4ec03d1013/pydantic_core-2.46.5-graalpy312-graalpy250_312_native-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8e24d8f05fa2d28513d94e877e9c75ad66175376209b3977f916e240e623193c", size = 2111034, upload-time = "2026-08-28T10:01:07.345Z" }, + { url = "https://files.pythonhosted.org/packages/20/21/22102e9950b3049526d20e811b95396508377d87651edd2b80d2b3d28659/pydantic_core-2.46.5-pp311-pypy311_pp73-macosx_10_12_x86_64.whl", hash = "sha256:ab4b66edffb32d9e951efb3814bd104b8367a7501b81b955cacb5726d897389f", size = 2071333, upload-time = "2026-08-28T10:01:09.636Z" }, + { url = "https://files.pythonhosted.org/packages/d8/18/87aefa427d191e6d3ab1447f1efc1cdcac86af1069239b133e8a0fd7f7c9/pydantic_core-2.46.5-pp311-pypy311_pp73-macosx_11_0_arm64.whl", hash = "sha256:337639ba62a11acde6ef3aeb08c8ea755f8ef1fe5e513356c0f36a2b0d7568b0", size = 1912713, upload-time = "2026-08-28T10:01:12.285Z" }, + { url = "https://files.pythonhosted.org/packages/1f/93/fd89e9ad49b1805ca94d24ce1088b7d305f05c35ffafcedb9819d03588a0/pydantic_core-2.46.5-pp311-pypy311_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:413a717a410d0c817ef5b786a059415550b3794e1d0c2abffd9efb93a3d9f7b4", size = 2090926, upload-time = "2026-08-28T10:01:15.19Z" }, + { url = "https://files.pythonhosted.org/packages/6f/45/8e59dab6acf8d35f02f0a958980074f31038968bdb2c983fcae9d1efee03/pydantic_core-2.46.5-pp311-pypy311_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:1e449def1945a462c464331254e5a44fca7c3b4f9aedf59ec2f50f8066dd8e25", size = 2131303, upload-time = "2026-08-28T10:01:17.937Z" }, + { url = "https://files.pythonhosted.org/packages/d5/a5/e1d4dc5180dd887a9522efc1f8716b8692b7606b1d3273d7862eaf66be44/pydantic_core-2.46.5-pp311-pypy311_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:a445486499897b88a7d6c310c88ed64dd37b1b59bfd7ae9107490bbb362f47d6", size = 2145128, upload-time = "2026-08-28T10:01:20.694Z" }, + { url = "https://files.pythonhosted.org/packages/c2/d7/ad493864a7fb21c0c4df98f965e2db430cb25a9d7369b5778d5016c09fd9/pydantic_core-2.46.5-pp311-pypy311_pp73-musllinux_1_1_armv7l.whl", hash = "sha256:2d330aaba8621b1edcec8ae2c4050f63b84ccf6d98723a8f212e9684713abf0e", size = 2294560, upload-time = "2026-08-28T10:01:23.495Z" }, + { url = "https://files.pythonhosted.org/packages/02/8e/b41c84c913f29973a268e6c2b5bbf13c95adb9956c126d10da11ba3b2bef/pydantic_core-2.46.5-pp311-pypy311_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:b6acfb46a814762367fb7ba0828b0a17d441b92ce249a0e007474c9072662dda", size = 2317531, upload-time = "2026-08-28T10:01:26.334Z" }, + { url = "https://files.pythonhosted.org/packages/db/1d/068464f23075f66a8f1b806935e9cd9363ee446636ea70d2c22ee8659dbf/pydantic_core-2.46.5-pp311-pypy311_pp73-win_amd64.whl", hash = "sha256:d0a24b40877af2de4950252be9d21eaf7fb07660f3c2cae1f56c6b599ada5266", size = 2140686, upload-time = "2026-08-28T10:01:28.947Z" }, ] [[package]] @@ -5267,7 +5309,7 @@ wheels = [ [[package]] name = "semantic-kernel" -version = "1.36.0" +version = "1.44.0" source = { registry = "https://pypi.org/simple" } dependencies = [ { name = "aiohttp" }, @@ -5278,6 +5320,7 @@ dependencies = [ { name = "cloudevents" }, { name = "defusedxml" }, { name = "jinja2" }, + { name = "mcp" }, { name = "nest-asyncio" }, { name = "numpy" }, { name = "openai" }, @@ -5285,7 +5328,6 @@ dependencies = [ { name = "opentelemetry-api" }, { name = "opentelemetry-sdk" }, { name = "prance" }, - { name = "protobuf" }, { name = "pybars4" }, { name = "pydantic" }, { name = "pydantic-settings" }, @@ -5294,9 +5336,9 @@ dependencies = [ { name = "typing-extensions" }, { name = "websockets" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/ef/5f/f87a637d594dd5627352ab83d5929e650e28c15b7b150205c32ecb02a77a/semantic_kernel-1.36.0.tar.gz", hash = "sha256:3b825fb8180e96ad69efd1916198bd403f5cfd9fc937a7e0de305d663e190fb0", size = 575250, upload-time = "2025-08-27T05:12:37.856Z" } +sdist = { url = "https://files.pythonhosted.org/packages/b4/54/e7463814430dc2846680b17c05fb464b8bf3aa70f38500de74cf01060370/semantic_kernel-1.44.0.tar.gz", hash = "sha256:8a3bfdda7663e1a6165da3fe03f418a3622ac24bb3fde970ad24cbeb5fca79b3", size = 622652, upload-time = "2026-07-07T09:02:08.146Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/7b/ed/266fe04403eafaf725ce9be1a4c2780e4f271c54641e14ab786c51384cbc/semantic_kernel-1.36.0-py3-none-any.whl", hash = "sha256:5d6c9a7ee387c31a86b693c0d90d6cf2106c2ddb98b74ab9f61f761c9fe1d919", size = 883186, upload-time = "2025-08-27T05:12:35.883Z" }, + { url = "https://files.pythonhosted.org/packages/d6/7c/e5970cd25c62412cee46d6ad03afe4249cfdf7c684874aa1f6202eea1fff/semantic_kernel-1.44.0-py3-none-any.whl", hash = "sha256:3fe389d7c4d85e0a18c069fa43a4d7a526d34f7ba0fc291f2dba3d85963d7fed", size = 934895, upload-time = "2026-07-07T09:02:06.252Z" }, ] [[package]] @@ -5681,6 +5723,15 @@ wheels = [ { url = "https://files.pythonhosted.org/packages/49/f6/73c4aa003d1237ee9bea8a46f49dc38c45dfe95af4f0da7e60678d388011/trove_classifiers-2025.11.14.15-py3-none-any.whl", hash = "sha256:d1dac259c1e908939862e3331177931c6df0a37af2c1a8debcc603d9115fcdd9", size = 14191, upload-time = "2025-11-14T15:23:12.467Z" }, ] +[[package]] +name = "truststore" +version = "0.10.4" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/53/a3/1585216310e344e8102c22482f6060c7a6ea0322b63e026372e6dcefcfd6/truststore-0.10.4.tar.gz", hash = "sha256:9d91bd436463ad5e4ee4aba766628dd6cd7010cf3e2461756b3303710eebc301", size = 26169, upload-time = "2025-08-12T18:49:02.73Z" } +wheels = [ + { url = "https://files.pythonhosted.org/packages/19/97/56608b2249fe206a67cd573bc93cd9896e1efb9e98bce9c163bcdc704b88/truststore-0.10.4-py3-none-any.whl", hash = "sha256:adaeaecf1cbb5f4de3b1959b42d41f6fab57b2b1666adb59e89cb0b53361d981", size = 18660, upload-time = "2025-08-12T18:49:01.46Z" }, +] + [[package]] name = "typer" version = "0.24.1" From 28030b8ed49a7a65bd0cec9aa823dbf467b635da Mon Sep 17 00:00:00 2001 From: aniketwaghh Date: Mon, 31 Aug 2026 11:25:27 +0530 Subject: [PATCH 4/4] fix(mcp): make the 1.x deprecation notice reachable and import-safe The notice added in 9abed5e did not work. Two problems, both real, found by cubic on #3030 and reproduced against mcp 1.29.1 before changing anything. Python's default filters hide DeprecationWarning outside __main__, so raising one from a library module meant the notice never reached the 1.x users it was written for. `python -c "import chainlit"` on mcp 1.29.1 printed nothing. The original verification was wrong rather than the finding: it used warnings.simplefilter("always"), which overrode the very filters that suppress the notice in a real run, so it proved the warning was emitted and not that anyone would see it. Worse, the warning fired while chainlit was being imported, since callbacks.py imports mcp.py. Under PYTHONWARNINGS=error a deprecation notice became a hard import failure for exactly the 1.x users it targets, which breaks this repo's backward-compatibility rule. Logging instead of warning fixes both: it is visible by default and can never raise. Moved to the MCP connection path so it costs nothing for apps that never use MCP, and emitted once so repeated connections do not repeat it. Verified on mcp 1.29.1: the notice appears on a plain logging setup, and `import chainlit` succeeds with warnings-as-errors scoped to it. Silent on 2.1.1. Tests cover both the visibility and the import-safety property, so this cannot regress the way the first attempt did. 944 backend tests, lint, format, mypy and actionlint clean. --- backend/chainlit/mcp.py | 44 ++++++++++++++++++++--------- backend/chainlit/server.py | 3 ++ backend/tests/test_mcp.py | 58 ++++++++++++++++++++++++++++++++++++++ 3 files changed, 91 insertions(+), 14 deletions(-) diff --git a/backend/chainlit/mcp.py b/backend/chainlit/mcp.py index 0b76f64b04..c348da9ee5 100644 --- a/backend/chainlit/mcp.py +++ b/backend/chainlit/mcp.py @@ -1,4 +1,3 @@ -import warnings from importlib.metadata import version from types import ModuleType from typing import Callable, Dict, Literal, Optional, Union @@ -7,6 +6,8 @@ import httpx from pydantic import BaseModel +from chainlit.logger import logger + class StdioMcpConnection(BaseModel): name: str @@ -257,26 +258,41 @@ def check(url: str) -> None: _MCP_HTTP_SSE_READ_TIMEOUT = 300.0 -def _warn_if_mcp_1x() -> None: - """Warn once, at import, when the resolved MCP SDK is still on 1.x. +_mcp_1x_notice_emitted = False + + +def warn_if_mcp_1x() -> None: + """Log once, on first MCP use, when the resolved SDK is still on 1.x. chainlit supports ``mcp>=1.28.1,<3.0.0`` but only resolves and tests against 2.x. 1.x still works today and the floor is deliberately left where it is, so this is a heads-up rather than a breakage: the intent is to raise the floor to ``>=2`` once 1.x stops being worth carrying, and anyone pinned below that wants notice before it happens. - """ - if version("mcp").startswith("1."): - warnings.warn( - "chainlit resolved mcp 1.x. Support for mcp<2 is deprecated and " - "will be removed in a future release; pin mcp>=2 to stay ahead " - "of it.", - DeprecationWarning, - stacklevel=2, - ) - -_warn_if_mcp_1x() + Logged rather than raised as a ``DeprecationWarning`` for two reasons. + Python's default filters hide ``DeprecationWarning`` outside ``__main__``, + so from a library module the notice would never reach the users it is for. + And a warning raised while ``chainlit`` is being imported becomes an + exception under ``PYTHONWARNINGS=error``, which would turn a deprecation + notice into a hard import failure for the 1.x users it targets. Called + from the MCP connection path so it costs nothing for apps that never use + MCP. + """ + global _mcp_1x_notice_emitted + + if _mcp_1x_notice_emitted: + return + installed = version("mcp") + if not installed.startswith("1."): + return + + _mcp_1x_notice_emitted = True + logger.warning( + "chainlit resolved mcp %s. Support for mcp<2 is deprecated and will be " + "removed in a future release; pin mcp>=2 to stay ahead of it.", + installed, + ) def _mcp_http_module() -> ModuleType: diff --git a/backend/chainlit/server.py b/backend/chainlit/server.py index ceba6de601..ff252f263d 100644 --- a/backend/chainlit/server.py +++ b/backend/chainlit/server.py @@ -1452,9 +1452,12 @@ async def connect_mcp( make_mcp_streamable_http_client, validate_mcp_headers, validate_mcp_url, + warn_if_mcp_1x, ) from chainlit.session import McpSession, WebsocketSession, stop_mcp_task + warn_if_mcp_1x() + session = WebsocketSession.get_by_id(payload.sessionId) context = init_ws_context(session) config: ChainlitConfig = session.get_config() diff --git a/backend/tests/test_mcp.py b/backend/tests/test_mcp.py index 2a38b746dd..78daf635e3 100644 --- a/backend/tests/test_mcp.py +++ b/backend/tests/test_mcp.py @@ -1,4 +1,5 @@ import asyncio +import importlib import inspect import logging import time @@ -2586,3 +2587,60 @@ def test_stdio_server_secrets_not_disclosed( assert "command" not in server assert "url" not in server assert "headers" not in server + + +@pytest.mark.parametrize( + ("installed", "expected"), + [("1.29.1", True), ("1.28.1", True), ("2.1.1", False), ("2.0.0", False)], +) +def test_mcp_1x_notice_is_logged_only_for_1x(monkeypatch, caplog, installed, expected): + """The 1.x deprecation notice has to actually reach the user. + + It is logged rather than raised as a DeprecationWarning because Python's + default filters hide that category outside __main__, so a warnings-based + notice from this module would be invisible to the 1.x users it is for. + """ + import chainlit.mcp as mcp_module + + monkeypatch.setattr(mcp_module, "_mcp_1x_notice_emitted", False) + monkeypatch.setattr(mcp_module, "version", lambda _: installed) + + with caplog.at_level(logging.WARNING, logger="chainlit"): + mcp_module.warn_if_mcp_1x() + + emitted = [r for r in caplog.records if "mcp<2 is deprecated" in r.getMessage()] + assert bool(emitted) is expected + if expected: + assert installed in emitted[0].getMessage() + + +def test_mcp_1x_notice_is_logged_once(monkeypatch, caplog): + """Repeated MCP connections must not repeat the notice.""" + import chainlit.mcp as mcp_module + + monkeypatch.setattr(mcp_module, "_mcp_1x_notice_emitted", False) + monkeypatch.setattr(mcp_module, "version", lambda _: "1.29.1") + + with caplog.at_level(logging.WARNING, logger="chainlit"): + mcp_module.warn_if_mcp_1x() + mcp_module.warn_if_mcp_1x() + mcp_module.warn_if_mcp_1x() + + emitted = [r for r in caplog.records if "mcp<2 is deprecated" in r.getMessage()] + assert len(emitted) == 1 + + +def test_importing_chainlit_emits_no_warning_on_mcp_1x(): + """Importing chainlit must not warn, whatever the resolved SDK. + + A warning raised during import becomes an exception under + PYTHONWARNINGS=error, which would make a deprecation notice a hard import + failure for the 1.x users it targets. + """ + import warnings + + with warnings.catch_warnings(record=True) as caught: + warnings.simplefilter("always") + importlib.reload(importlib.import_module("chainlit.mcp")) + + assert [w for w in caught if "mcp<2" in str(w.message)] == []