Running the test suite on macOS (observed on GitHub macos-latest, Python 3.14) fails one test that passes on Ubuntu and Windows:
FAILED tests/server/test_streamable_http_modern.py::test_modern_post_with_deeply_nested_body_is_parse_error_not_a_crash
> assert response.json()["error"]["code"] == PARSE_ERROR
E assert -32600 == -32700
|
async def test_modern_post_with_deeply_nested_body_is_parse_error_not_a_crash() -> None: |
The response status is 400 in both cases; only the JSON-RPC error code differs. The test expects the RecursionError raised while parsing the deeply nested body to classify as a parse error, but on Darwin it surfaces as INVALID_REQUEST, so the recursion limit is evidently being hit in a different layer there (macOS threads run with a smaller default stack, which moves where the recursion guard strikes).
This is unrelated to any open PR: it fails identically on current main (3a6f299) and on feature branches, reproduced across repeated runs on macos-latest. Repro:
uv sync --frozen
uv run --frozen pytest tests/server/test_streamable_http_modern.py::test_modern_post_with_deeply_nested_body_is_parse_error_not_a_crash
CI currently runs Ubuntu and Windows only, which is why this has gone unnoticed; worth deciding separately whether macos-latest should join the matrix.
AI Disclaimer
Running the test suite on macOS (observed on GitHub
macos-latest, Python 3.14) fails one test that passes on Ubuntu and Windows:python-sdk/tests/server/test_streamable_http_modern.py
Line 1011 in 3a6f299
The response status is 400 in both cases; only the JSON-RPC error code differs. The test expects the RecursionError raised while parsing the deeply nested body to classify as a parse error, but on Darwin it surfaces as INVALID_REQUEST, so the recursion limit is evidently being hit in a different layer there (macOS threads run with a smaller default stack, which moves where the recursion guard strikes).
This is unrelated to any open PR: it fails identically on current
main(3a6f299) and on feature branches, reproduced across repeated runs onmacos-latest. Repro:CI currently runs Ubuntu and Windows only, which is why this has gone unnoticed; worth deciding separately whether
macos-latestshould join the matrix.AI Disclaimer