pre-commit-ci-lite[bot]
24b68a5fdb
🎨 Auto format
5 months ago
Varun Chawla
226e064009
Clarify documentation for required query params with None type
Fixes #12419
**Problem:**
The documentation section "Required, can be None" was misleading. It suggested
that you could force clients to send a None value, but HTTP query parameters
cannot send literal None - they're either strings or omitted entirely.
The example showed `q: Annotated[str | None, Query(min_length=3)]` without a
default value, which makes the parameter required. However, there's no way for
a client to satisfy this by sending None via HTTP query parameters.
**Solution:**
Updated the documentation to:
1. Rename the section to "Required with None type" to be more accurate
2. Add a detailed note explaining HTTP query parameter limitations
3. Clarify that omitting the parameter results in a validation error
4. Explain this pattern is more useful for dependencies than HTTP endpoints
5. Show the correct pattern for optional parameters that can be omitted
**Testing:**
The existing tests in test_tutorial006c.py are already marked as xfail with a
reference to this issue, confirming the example doesn't work as described. This
documentation update clarifies the behavior instead of changing the example to
something that would work differently.
This helps developers understand when to use this pattern (dependencies) vs
when to use optional parameters with defaults (HTTP endpoints).
5 months ago
github-actions[bot]
c48539f4c6
📝 Update release notes
[skip ci]
5 months ago
Sebastián Ramírez
2e7d3754cd
♻️ Refactor and simplify Pydantic v2 (and v1) compatibility internal utils ( #14862 )
5 months ago
Sebastián Ramírez
8eac94bd91
🔖 Release version 0.128.4
5 months ago
github-actions[bot]
58cdfc7f4b
📝 Update release notes
[skip ci]
5 months ago
Sebastián Ramírez
d59fbc3494
♻️ Refactor internals, simplify Pydantic v2/v1 utils, `create_model_field`, better types for `lenient_issubclass` ( #14860 )
5 months ago
github-actions[bot]
cc6ced6345
📝 Update release notes
[skip ci]
5 months ago
Sebastián Ramírez
cf55bade7e
♻️ Simplify internals, remove Pydantic v1 only logic, no longer needed ( #14857 )
5 months ago
github-actions[bot]
ac8362c447
📝 Update release notes
[skip ci]
5 months ago
Sebastián Ramírez
3c49346238
♻️ Refactor internals, cleanup unneeded Pydantic v1 specific logic ( #14856 )
5 months ago
github-actions[bot]
512c3ad88c
📝 Update release notes
[skip ci]
5 months ago
Motov Yurii
cba537ab71
🌐 Update translations for fr (outdated pages) ( #14839 )
5 months ago
github-actions[bot]
2eb454ab04
📝 Update release notes
[skip ci]
5 months ago
Motov Yurii
0f5987b560
🌐 Update translations for tr (outdated and missing) ( #14838 )
5 months ago
github-actions[bot]
266a3138b5
📝 Update release notes
[skip ci]
5 months ago
Sebastián Ramírez
5a31b37cc7
⬆️ Upgrade development dependencies ( #14854 )
5 months ago
Sebastián Ramírez
36985f5f25
🔖 Release version 0.128.3
5 months ago
github-actions[bot]
661cdfb8a4
📝 Update release notes
[skip ci]
5 months ago
Sebastián Ramírez
f6cc650a12
⬆️ Upgrade Starlette supported version range to `starlette>=0.40.0,<1.0.0` ( #14853 )
5 months ago
github-actions[bot]
201feedd68
📝 Update release notes
[skip ci]
5 months ago
Sebastián Ramírez
19f13ead4c
👷 Run tests with Starlette from git ( #14849 )
5 months ago
github-actions[bot]
01e85c03bd
📝 Update release notes
[skip ci]
5 months ago
Sebastián Ramírez
08233d7ffc
🌐 Update translations for ru (update-outdated) ( #14834 )
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
5 months ago
github-actions[bot]
fe8c33ea64
📝 Update release notes
[skip ci]
5 months ago
Sebastián Ramírez
f9f7992604
♻️ Re-implement `on_event` in FastAPI for compatibility with the next Starlette, while keeping backwards compatibility ( #14851 )
5 months ago
github-actions[bot]
8e50c55fd9
📝 Update release notes
[skip ci]
5 months ago
Sebastián Ramírez
3b8b310eda
👷 Run tests with lower bound uv sync, upgrade `fastapi[all]` minimum dependencies: `ujson >=5.8.0`, `orjson >=3.9.3` ( #14846 )
5 months ago
Sebastián Ramírez
79406a4b04
🔖 Release version 0.128.2
5 months ago
github-actions[bot]
de56c96c64
📝 Update release notes
[skip ci]
5 months ago
Sebastián Ramírez
570e592a03
🌐 Enable Traditional Chinese translations ( #14842 )
5 months ago
github-actions[bot]
110b45d9b2
📝 Update release notes
[skip ci]
5 months ago
Sebastián Ramírez
72325f698f
🌐 Enable French docs translations ( #14841 )
5 months ago
github-actions[bot]
8bdbd3725f
📝 Update release notes
[skip ci]
5 months ago
Sebastián Ramírez
23ddf09dd1
🔨 Add max pages to translate to configs ( #14840 )
5 months ago
github-actions[bot]
6646e2b94f
📝 Update release notes
[skip ci]
5 months ago
Kanetsuna Masaya
c5fd75a321
🐛 Fix using `Json[list[str]]` type (issue #10997 ) ( #14616 )
Co-authored-by: pre-commit-ci-lite[bot] <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com>
Co-authored-by: Motov Yurii <[email protected] >
Co-authored-by: Sebastián Ramírez <[email protected] >
5 months ago
github-actions[bot]
54f8aeeb9a
📝 Update release notes
[skip ci]
5 months ago
Albin Skott
97145588f5
✨ Add support for PEP695 `TypeAliasType` ( #13920 )
Co-authored-by: lokidev <[email protected] >
Co-authored-by: Motov Yurii <[email protected] >
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Yurii Motov <[email protected] >
Co-authored-by: Sebastián Ramírez <[email protected] >
5 months ago
github-actions[bot]
0dd42b746e
📝 Update release notes
[skip ci]
5 months ago
Jonathan Fulton
b49435becd
✨ Allow `Response` type hint as dependency annotation ( #14794 )
Co-authored-by: pre-commit-ci-lite[bot] <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com>
Co-authored-by: Motov Yurii <[email protected] >
Co-authored-by: Sebastián Ramírez <[email protected] >
5 months ago
github-actions[bot]
464c359bb0
📝 Update release notes
[skip ci]
5 months ago
Sebastián Ramírez
457cd75c23
🌐 Update translations for fr (translate-page) ( #14837 )
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
5 months ago
github-actions[bot]
2838dcb4a8
📝 Update release notes
[skip ci]
5 months ago
github-actions[bot]
b82993643e
📝 Update release notes
[skip ci]
5 months ago
Sebastián Ramírez
b892c3126c
🌐 Update translations for de (update-outdated) ( #14836 )
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
5 months ago
github-actions[bot]
3578270af4
📝 Update release notes
[skip ci]
5 months ago
Sebastián Ramírez
2224b4e63b
🌐 Update translations for pt (update-outdated) ( #14833 )
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
5 months ago
Sebastián Ramírez
136d5f0a56
🌐 Update translations for ko (update-outdated) ( #14835 )
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
5 months ago
github-actions[bot]
afb44f0ff8
📝 Update release notes
[skip ci]
5 months ago