From 16cf1e3def2d3e4760ec1b00715ea5a8d684f243 Mon Sep 17 00:00:00 2001 From: Wu Clan Date: Sun, 9 Nov 2025 15:39:32 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=F0=9F=93=9D=20Update=20user=20tutorial=20a?= =?UTF-8?q?rticle=20categories?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../en/docs/advanced/advanced-dependencies.md | 2 +- docs/en/mkdocs.yml | 44 +++++++++++-------- scripts/docs.py | 2 +- 3 files changed, 27 insertions(+), 21 deletions(-) diff --git a/docs/en/docs/advanced/advanced-dependencies.md b/docs/en/docs/advanced/advanced-dependencies.md index 5d6a40f463..37f5c78f2d 100644 --- a/docs/en/docs/advanced/advanced-dependencies.md +++ b/docs/en/docs/advanced/advanced-dependencies.md @@ -144,7 +144,7 @@ This was changed in version 0.110.0 to fix unhandled memory consumption from for ### Background Tasks and Dependencies with `yield`, Technical Details { #background-tasks-and-dependencies-with-yield-technical-details } -Before FastAPI 0.106.0, raising exceptions after `yield` was not possible, the exit code in dependencies with `yield` was executed *after* the response was sent, so [Exception Handlers](../handling-errors.md#install-custom-exception-handlers){.internal-link target=_blank} would have already run. +Before FastAPI 0.106.0, raising exceptions after `yield` was not possible, the exit code in dependencies with `yield` was executed *after* the response was sent, so [Exception Handlers](../tutorial/handling-errors.md#install-custom-exception-handlers){.internal-link target=_blank} would have already run. This was designed this way mainly to allow using the same objects "yielded" by dependencies inside of background tasks, because the exit code would be executed after the background tasks were finished. diff --git a/docs/en/mkdocs.yml b/docs/en/mkdocs.yml index 323035240a..deb0997deb 100644 --- a/docs/en/mkdocs.yml +++ b/docs/en/mkdocs.yml @@ -108,32 +108,38 @@ nav: - Tutorial - User Guide: - tutorial/index.md - tutorial/first-steps.md - - tutorial/path-params.md - - tutorial/query-params.md - - tutorial/body.md - - tutorial/query-params-str-validations.md - - tutorial/path-params-numeric-validations.md - - tutorial/query-param-models.md - - tutorial/body-multiple-params.md - - tutorial/body-fields.md - - tutorial/body-nested-models.md + - Path: + - tutorial/path-params.md + - tutorial/path-params-numeric-validations.md + - tutorial/path-operation-configuration.md + - Query: + - tutorial/query-params.md + - tutorial/query-params-str-validations.md + - tutorial/query-param-models.md + - Body: + - tutorial/body.md + - tutorial/body-multiple-params.md + - tutorial/body-fields.md + - tutorial/body-nested-models.md + - tutorial/body-updates.md + - Cookie: + - tutorial/cookie-params.md + - tutorial/cookie-param-models.md + - Header: + - tutorial/header-params.md + - tutorial/header-param-models.md + - Form and File: + - tutorial/request-forms.md + - tutorial/request-form-models.md + - tutorial/request-files.md + - tutorial/request-forms-and-files.md - tutorial/schema-extra-example.md - tutorial/extra-data-types.md - - tutorial/cookie-params.md - - tutorial/header-params.md - - tutorial/cookie-param-models.md - - tutorial/header-param-models.md - tutorial/response-model.md - tutorial/extra-models.md - tutorial/response-status-code.md - - tutorial/request-forms.md - - tutorial/request-form-models.md - - tutorial/request-files.md - - tutorial/request-forms-and-files.md - tutorial/handling-errors.md - - tutorial/path-operation-configuration.md - tutorial/encoder.md - - tutorial/body-updates.md - Dependencies: - tutorial/dependencies/index.md - tutorial/dependencies/classes-as-dependencies.md diff --git a/scripts/docs.py b/scripts/docs.py index 56ffb9d364..558f087598 100644 --- a/scripts/docs.py +++ b/scripts/docs.py @@ -297,7 +297,7 @@ def live( if dirty: args.append("--dirty") subprocess.run( - args, env={**os.environ, "LINENUMS": "true"}, cwd=lang_path, check=True + args, env={**os.environ, "LINENUMS": "true", "PYTHONUTF8": "1"}, cwd=lang_path, check=True ) From 3b98ce9c84d643d77ac6c9e6441b968665fff576 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sun, 9 Nov 2025 07:51:15 +0000 Subject: [PATCH 2/3] =?UTF-8?q?=F0=9F=8E=A8=20[pre-commit.ci]=20Auto=20for?= =?UTF-8?q?mat=20from=20pre-commit.com=20hooks?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/docs.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/scripts/docs.py b/scripts/docs.py index 558f087598..44e84e01a8 100644 --- a/scripts/docs.py +++ b/scripts/docs.py @@ -297,7 +297,10 @@ def live( if dirty: args.append("--dirty") subprocess.run( - args, env={**os.environ, "LINENUMS": "true", "PYTHONUTF8": "1"}, cwd=lang_path, check=True + args, + env={**os.environ, "LINENUMS": "true", "PYTHONUTF8": "1"}, + cwd=lang_path, + check=True, ) From 16984ec2015aca0db7c28d442f79438375549a22 Mon Sep 17 00:00:00 2001 From: Wu Clan Date: Sun, 9 Nov 2025 15:58:57 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=F0=9F=94=A7=20Restore=20path-operation-con?= =?UTF-8?q?figuration.md?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/en/mkdocs.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/en/mkdocs.yml b/docs/en/mkdocs.yml index deb0997deb..44c33439ab 100644 --- a/docs/en/mkdocs.yml +++ b/docs/en/mkdocs.yml @@ -111,7 +111,6 @@ nav: - Path: - tutorial/path-params.md - tutorial/path-params-numeric-validations.md - - tutorial/path-operation-configuration.md - Query: - tutorial/query-params.md - tutorial/query-params-str-validations.md @@ -139,6 +138,7 @@ nav: - tutorial/extra-models.md - tutorial/response-status-code.md - tutorial/handling-errors.md + - tutorial/path-operation-configuration.md - tutorial/encoder.md - Dependencies: - tutorial/dependencies/index.md