]> git.ipfire.org Git - thirdparty/fastapi/fastapi.git/commitdiff
📝 Fix code include for Pydantic models example in `docs/zh/docs/python-types.md`...
authorMika <44454249+anfreshman@users.noreply.github.com>
Mon, 18 Aug 2025 06:34:40 +0000 (14:34 +0800)
committerGitHub <noreply@github.com>
Mon, 18 Aug 2025 06:34:40 +0000 (08:34 +0200)
Updated the Pydantic expiration example in the Chinese documentation

docs/zh/docs/python-types.md

index ba767da879f5c5800d417f486ea539a28b62e653..a7f76d97fa259307cded7ade5185947f1208b5e2 100644 (file)
@@ -240,7 +240,29 @@ John Doe
 
 下面的例子来自 Pydantic 官方文档:
 
-{* ../../docs_src/python_types/tutorial010.py *}
+//// tab | Python 3.10+
+
+```Python
+{!> ../../docs_src/python_types/tutorial011_py310.py!}
+```
+
+////
+
+//// tab | Python 3.9+
+
+```Python
+{!> ../../docs_src/python_types/tutorial011_py39.py!}
+```
+
+////
+
+//// tab | Python 3.8+
+
+```Python
+{!> ../../docs_src/python_types/tutorial011.py!}
+```
+
+////
 
 
 /// info