pre-commit-ci-lite[bot]
f84ced1f99
🎨 Auto format
2 weeks ago
valbort
09aa17942a
🐛 Fix ty (pyright) type checking errors
2 weeks ago
valbort
e893e7886b
🐛 Fix mypy type checking errors for Pydantic v2 optimizations
2 weeks ago
valbort
59b376c7f9
🙈 Ignore NotImplementedError fallback in coverage
The NotImplementedError fallback is only hit by older Pydantic versions in the test matrix. Added # pragma: no cover so the 100% coverage requirement passes for modern environments.
2 weeks ago
valbort
750285ecbe
🎨 Format code and add NotImplementedError fallback
Added a fallback to json.loads when Pydantic's validate_json throws NotImplementedError. This fixes compatibility issues with older Pydantic versions in CI testing for endpoints utilizing arbitrary types (like Missing). Also ran Ruff to fix formatting and linting issues reported by pre-commit hooks.
2 weeks ago
pre-commit-ci-lite[bot]
30ef0e833a
🎨 Auto format
2 weeks ago
valbort
2ed93650a1
✅ Update tests for Pydantic v2 JSON decode errors
Since we bypass json.loads and parse bytes directly via Pydantic, the JSON decode errors now return standard Pydantic v2 validation errors. Tests have been updated to expect this cleaner format.
2 weeks ago
valbort
886cd92b5e
🐛 Fix double JSON parsing from request body
Remove the 'await request.json()' call which was inadvertently left in the routing path. This ensures that the body bytes are passed directly to Pydantic's validate_json via FastAPIOptimizedJsonBytes, bypassing unnecessary Python dict allocations entirely.
2 weeks ago
valbort
40e2198b15
⚡ Cache pydantic.v1 import to minimize compatibility overhead
Moving the import of pydantic.v1 and the warnings filter to the module level avoids executing them on every single object serialization in jsonable_encoder, significantly boosting performance for Pydantic v1 backward compatibility checks.
2 weeks ago
valbort
35ea1fee95
✨ Optimize request parameter validation via synthetic models
Group validation of multiple parameters (query, path, headers, cookies) into a single Pydantic call using a dynamically generated BaseModel.
- Introduce get_grouped_adapter with lru_cache to cache synthetic models
- Replace individual parameter validation loop with validate_python
- Reconstruct FastAPI-compatible ValidationError structure to ensure complete backwards compatibility for error locations and input fields.
2 weeks ago
valbort
22aee4522f
✨ Optimize response serialization using Pydantic v2 TypeAdapter
This commit introduces a fast-path for the jsonable_encoder and directly uses TypeAdapter(Any).dump_json() and dump_python() in astapi.routing and astapi.encoders. By leveraging the Rust-based pydantic-core directly, serialization overhead for complex types is significantly reduced.
- Use TypeAdapter(Any).dump_json() in _serialize_data and _serialize_sse_item
- Add fast-path to jsonable_encoder to use TypeAdapter(Any).dump_python(mode='json')
- Update test_sse_events_with_fields to account for minified JSON output of Pydantic v2
2 weeks ago
valbort
1bffdc5f36
Optimize JSON parsing by using Pydantic V2 validate_json directly from request body bytes. - Add FastAPIOptimizedJsonBytes helper to mark bytes for optimized parsing. - Implement validate_json in ModelField to leverage pydantic-core's native JSON parsing. - Update get_request_handler to pass raw body bytes wrapped in FastAPIOptimizedJsonBytes when applicable. - Update _validate_value_with_model_field to use validate_json when receiving optimized bytes, avoiding redundant Python dict conversion.
Co-authored-by: Junie <[email protected] >
3 weeks ago
github-actions[bot]
e89a37e50d
📝 Update release notes
[skip ci]
4 weeks ago
dependabot[bot]
5d5666bec5
⬆ Bump ty from 0.0.21 to 0.0.34 ( #15443 )
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: svlandeg <[email protected] >
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
4 weeks ago
github-actions[bot]
7cb195394c
📝 Update release notes
[skip ci]
4 weeks ago
dependabot[bot]
3ec959abc7
⬆ Bump pydantic from 2.13.2 to 2.13.3 ( #15444 )
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
4 weeks ago
github-actions[bot]
622b6356b5
📝 Update release notes
[skip ci]
1 month ago
Sebastián Ramírez
fb7429378d
👷 Add pre-commit to check typos ( #15482 )
1 month ago
github-actions[bot]
3efd86c1fd
📝 Update release notes
[skip ci]
1 month ago
Carlos Rodríguez Romo
f8cbeabf81
🌐 Fix typos in Spanish LLM-prompt ( #15472 )
Co-authored-by: Motov Yurii <[email protected] >
1 month ago
github-actions[bot]
8c660a6819
📝 Update release notes
[skip ci]
1 month ago
Isaac
810fd2a888
✏️ Fix Azkaban spelling typo in `virtual-environments.md` ( #15463 )
1 month ago
github-actions[bot]
ecf73d61c3
📝 Update release notes
[skip ci]
1 month ago
Sebastián Ramírez
9ccaab154a
👥 Update FastAPI GitHub topic repositories ( #15470 )
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
1 month ago
github-actions[bot]
f72afb6f6e
📝 Update release notes
[skip ci]
1 month ago
Sebastián Ramírez
8da79ec2fe
👥 Update FastAPI People - Experts ( #15471 )
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
1 month ago
github-actions[bot]
205bd85a46
📝 Update release notes
[skip ci]
1 month ago
Sebastián Ramírez
bc8b1d101c
👥 Update FastAPI People - Contributors and Translators ( #15467 )
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
1 month ago
github-actions[bot]
e0a2c75b1a
📝 Update release notes
[skip ci]
1 month ago
Motov Yurii
33ed5aecdf
👷 Fix missing credentials issue in `translate` workflow ( #15468 )
1 month ago
github-actions[bot]
d8a2c1edaa
📝 Update release notes
[skip ci]
1 month ago
Alejandra
b363a1d002
💄 Improve layout and styling ( #15462 )
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
1 month ago
github-actions[bot]
a3ceb9ca74
📝 Update release notes
[skip ci]
1 month ago
Alejandra
aff0b7cd43
💄 Refactor opinions section with interactive tabs and new logos ( #15458 )
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
1 month ago
github-actions[bot]
6b20159c59
📝 Update release notes
[skip ci]
1 month ago
Alejandra
a217d2ff2a
📝 Add FastAPI Conf '26 announcement to docs ( #15457 )
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
1 month ago
github-actions[bot]
4f64b8f651
📝 Update release notes
[skip ci]
1 month ago
dependabot[bot]
1f7c8c1ad3
⬆ Bump sqlmodel from 0.0.32 to 0.0.38 ( #15437 )
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Motov Yurii <[email protected] >
1 month ago
github-actions[bot]
0e78824634
📝 Update release notes
[skip ci]
1 month ago
dependabot[bot]
4bad6d2597
⬆ Bump CodSpeedHQ/action from 4.12.1 to 4.14.0 ( #15436 )
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
1 month ago
github-actions[bot]
44ddc3e7c8
📝 Update release notes
[skip ci]
1 month ago
dependabot[bot]
edc4c8ba33
⬆ Bump pydantic from 2.12.5 to 2.13.2 ( #15439 )
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
1 month ago
github-actions[bot]
b44585589a
📝 Update release notes
[skip ci]
1 month ago
dependabot[bot]
f43cc1c0ef
⬆ Bump pydantic-ai from 1.63.0 to 1.83.0 ( #15417 )
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
1 month ago
github-actions[bot]
5c89b88c9f
📝 Update release notes
[skip ci]
1 month ago
dependabot[bot]
4216f99515
⬆ Bump prek from 0.3.2 to 0.3.9 ( #15418 )
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
1 month ago
github-actions[bot]
33aa27c7b7
📝 Update release notes
[skip ci]
1 month ago
dependabot[bot]
086048e395
⬆ Bump fastar from 0.9.0 to 0.11.0 ( #15419 )
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
1 month ago
github-actions[bot]
91dd310da9
📝 Update release notes
[skip ci]
1 month ago
dependabot[bot]
3747204677
⬆ Bump astral-sh/setup-uv from 7.6.0 to 8.1.0 ( #15415 )
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
1 month ago