- Sort Score
- Num 10 results
- Language All
Results 141 - 150 of 1,062 for python (0.12 seconds)
-
docs/zh-hant/docs/tutorial/header-params.md
在 `Path`、`Query`、`Cookie` 提供的功能之上,`Header` 還有一些額外的小功能。 大多數標準標頭的單字以連字號(減號,`-`)分隔。 但像 `user-agent` 這樣的變數名稱在 Python 中是無效的。 因此,`Header` 會在預設情況下把參數名稱中的底線(`_`)轉換為連字號(`-`),以便讀取並在文件中顯示該標頭。 此外,HTTP 標頭不區分大小寫,所以你可以使用標準的 Python 命名風格(snake_case)來宣告。 因此,你可以像在 Python 程式中一樣使用 `user_agent`,不需要把首字母大寫成 `User_Agent` 或類似寫法。 若因某些原因需要停用底線自動轉連字號的行為,將 `Header` 的 `convert_underscores` 參數設為 `False`:
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Sat Feb 14 08:15:26 GMT 2026 - 2.7K bytes - Click Count (0) -
scripts/tests/test_translation_fixer/test_code_blocks/data/translated_doc_number_gt.md
# Code blocks { #code-blocks } Some text ```python # This is a sample Python code block def hello_world(): # Comment with indentation print("Hello, world!") # Print greeting ``` Some more text ```toml # This is a sample TOML code block title = "TOML Example" # Title of the document ``` Extra code block ``` $ cd my_project ``` And more text ```consoleCreated: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Sat Jan 10 21:48:08 GMT 2026 - 926 bytes - Click Count (0) -
docs/ja/docs/history-design-future.md
## 設計 { #design } その後、 (FastAPIを使う開発者として) ユーザーが欲しい「API」の設計に時間を費やしました。 もっとも人気のあるPythonエディターでいくつかのアイデアをテストしました。PyCharm、VS Code、Jediベースのエディターです。 最新の [Python開発者調査](https://www.jetbrains.com/research/python-developers-survey-2018/#development-tools)で、それらのエディターがユーザーの80%をカバーしていました。 これは、**FastAPI**がPython開発者の80%が使用しているエディターで特別にテストされたことを意味します。また、ほとんどの他のエディターも同様に動作する傾向があるため、この恩恵は事実上すべてのエディターでうけられるはずです。Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Mar 20 14:07:17 GMT 2026 - 5.1K bytes - Click Count (0) -
docs/zh/docs/how-to/migrate-from-pydantic-v1-to-pydantic-v2.md
FastAPI 0.126.0 移除了对 Pydantic v1 的支持,但在一段时间内仍支持 `pydantic.v1`。 /// warning | 警告 从 Python 3.14 开始,Pydantic 团队不再为最新的 Python 版本提供 Pydantic v1 的支持。 这也包括 `pydantic.v1`,在 Python 3.14 及更高版本中不再受支持。 如果你想使用 Python 的最新特性,需要确保使用 Pydantic v2。 /// 如果你的旧 FastAPI 应用在用 Pydantic v1,这里将向你展示如何迁移到 Pydantic v2,以及 FastAPI 0.119.0 中可帮助你渐进式迁移的功能。 ## 官方指南 { #official-guide }Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Mar 20 17:06:37 GMT 2026 - 5.1K bytes - Click Count (0) -
docs/ja/docs/advanced/security/http-basic-auth.md
「タイミング攻撃」とは何でしょうか? 攻撃者がユーザー名とパスワードを推測しようとしていると想像してください。 そして、ユーザー名 `johndoe`、パスワード `love123` を使ってリクエストを送ります。 その場合、アプリケーション内の Python コードは次のようなものと等価になります: ```Python if "johndoe" == "stanleyjobson" and "love123" == "swordfish": ... ```
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Mar 20 14:07:17 GMT 2026 - 6.4K bytes - Click Count (0) -
.pre-commit-config.yaml
require_serial: true language: unsupported types: [python] - id: local-ruff-format name: ruff format entry: uv run ruff format --force-exclude --exit-non-zero-on-format require_serial: true language: unsupported types: [python] - id: local-mypy name: mypy check entry: uv run mypy fastapiCreated: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Apr 03 12:06:36 GMT 2026 - 2.6K bytes - Click Count (1) -
.github/workflows/smokeshow.yml
- name: Dump GitHub context env: GITHUB_CONTEXT: ${{ toJson(github) }} run: echo "$GITHUB_CONTEXT" - uses: actions/checkout@v6 - uses: actions/setup-python@v6 with: python-version-file: ".python-version" - name: Setup uv uses: astral-sh/setup-uv@v7 with: cache-dependency-glob: | pyproject.toml uv.lockCreated: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Tue Mar 03 00:12:02 GMT 2026 - 1.6K bytes - Click Count (0) -
docs/zh-hant/docs/history-design-future.md
接著,我花時間設計作為使用者(作為使用 FastAPI 的開發者)時希望擁有的開發者「API」。 我在最受歡迎的 Python 編輯器中測試了多個想法:PyCharm、VS Code、基於 Jedi 的編輯器。 根據最新的 [Python 開發者調查](https://www.jetbrains.com/research/python-developers-survey-2018/#development-tools),這些工具涵蓋約 80% 的使用者。 這表示 **FastAPI** 已針對 80% 的 Python 開發者所使用的編輯器進行過專門測試。而由於其他多數編輯器的行為也類似,這些優點擴及實際上幾乎所有編輯器。 藉此我找到了盡可能減少程式碼重複、在各處提供自動補全、型別與錯誤檢查等的最佳方式。 一切都是為了讓所有開發者都能擁有最佳的開發體驗。 ## 需求 { #requirements }Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Mar 20 17:05:38 GMT 2026 - 3.6K bytes - Click Count (0) -
scripts/tests/test_translation_fixer/test_code_blocks/data/translated_doc_mermaid_translated.md
Some text ```python # This is a sample Python code block def hello_world(): # Comment with indentation print("Hello, world!") # Print greeting ``` Some more text ```toml # This is a sample TOML code block title = "TOML Example" # Title of the document ``` And more text ```console // Use the command "live" and pass the language code as a CLI argument $ python ./scripts/docs.py live es
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Sat Jan 10 21:48:08 GMT 2026 - 889 bytes - Click Count (0) -
docs/ko/docs/advanced/settings.md
end ``` 우리의 의존성 `get_settings()`의 경우, 함수가 어떤 인자도 받지 않으므로 항상 같은 값을 반환합니다. 이렇게 하면 거의 전역 변수처럼 동작합니다. 하지만 의존성 함수를 사용하므로 테스트를 위해 쉽게 override할 수 있습니다. `@lru_cache`는 Python 표준 라이브러리의 `functools`에 포함되어 있으며, 자세한 내용은 [`@lru_cache`에 대한 Python 문서](https://docs.python.org/3/library/functools.html#functools.lru_cache)에서 확인할 수 있습니다. ## 정리 { #recap } Pydantic Settings를 사용하면 Pydantic 모델의 모든 강력한 기능을 활용해 애플리케이션의 설정 또는 구성을 처리할 수 있습니다.Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Mar 20 14:06:26 GMT 2026 - 11.9K bytes - Click Count (0)