fastmcp/tests/server/http
Jeremiah Lowin 07750efaab
Fix type errors for ty 0.0.1-alpha.31 upgrade (#2561)
* Fix type errors for ty 0.0.1-alpha.31 upgrade

Add type ignores and fixes for ty's stricter checking:
- Path(None) guards in cli.py
- isinstance checks for ElicitRequestFormParams (URL elicitation support)
- TODO(ty) comments for match/isinstance narrowing bugs
- Method override type ignores for generic covariance
- Starlette Middleware typing workarounds
- Dynamic type construction ignores in json_schema_type.py

* Fix remaining type errors for ty 0.0.1-alpha.31

- Add asserts for optional attribute access in tests
- Add type ignores for dynamic httpx transport internals
- Add TODO(ty) comments for `in` operator on str|bytes
- Add TODO(ty) comments for Starlette Middleware typing
- Use cast for prompt.fn async validation in server.py

* Upgrade ty to 0.0.1-alpha.31

Fixes additional test file type errors discovered after upgrade.
2025-12-05 21:29:14 -05:00
..
__init__.py clean up test inits 2025-05-31 19:32:08 -04:00
test_bearer_auth_backend.py Add documentation for get_access_token() dependency function (#1446) 2025-08-11 13:01:44 -04:00
test_custom_routes.py Internal refactor of MCP handlers (#2005) 2025-10-05 08:45:10 -04:00
test_http_auth_middleware.py Make CORS opt-in via middleware parameter (#2150) 2025-10-20 15:33:13 -04:00
test_http_dependencies.py Replace subprocess tests with in-process async servers (#2006) 2025-10-19 10:47:54 -04:00
test_http_middleware.py Fix type errors for ty 0.0.1-alpha.31 upgrade (#2561) 2025-12-05 21:29:14 -05:00
test_stale_access_token.py Fix get_access_token() returning stale token after OAuth refresh (#2505) 2025-12-01 10:51:02 -05:00