- Sort Score
- Num 10 results
- Language All
Results 211 - 220 of 1,875 for none (0.01 seconds)
-
tests/test_tutorial/test_separate_openapi_schemas/test_tutorial001.py
client = TestClient(mod.app) return client def test_create_item(client: TestClient) -> None: response = client.post("/items/", json={"name": "Foo"}) assert response.status_code == 200, response.text assert response.json() == {"name": "Foo", "description": None} def test_read_items(client: TestClient) -> None: response = client.get("/items/") assert response.status_code == 200, response.textCreated: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Sat Dec 20 15:55:38 GMT 2025 - 5K bytes - Click Count (0) -
scripts/deploy_docs_status.py
github_repository: str github_token: SecretStr deploy_url: str | None = None commit_sha: str run_id: int state: Literal["pending", "success", "error"] = "pending" class LinkData(BaseModel): previous_link: str preview_link: str en_link: str | None = None def main() -> None: logging.basicConfig(level=logging.INFO) settings = Settings()Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Tue Sep 30 05:56:53 GMT 2025 - 4.4K bytes - Click Count (0) -
docs/pt/docs/tutorial/response-model.md
Seu modelo de resposta pode ter valores padrão, como: {* ../../docs_src/response_model/tutorial004_py310.py hl[9,11:12] *} * `description: Union[str, None] = None` (ou `str | None = None` no Python 3.10) tem um padrão de `None`. * `tax: float = 10.5` tem um padrão de `10.5`. * `tags: List[str] = []` tem um padrão de uma lista vazia: `[]`.Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Dec 17 20:41:43 GMT 2025 - 17.3K bytes - Click Count (0) -
tests/test_required_noneable.py
from fastapi.testclient import TestClient app = FastAPI() @app.get("/query") def read_query(q: Union[str, None]): return q @app.get("/explicit-query") def read_explicit_query(q: Union[str, None] = Query()): return q @app.post("/body-embed") def send_body_embed(b: Union[str, None] = Body(embed=True)): return b client = TestClient(app) def test_required_nonable_query_invalid():
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Sat May 14 19:08:31 GMT 2022 - 1.5K bytes - Click Count (0) -
docs/fr/docs/tutorial/body-multiple-params.md
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Sat Nov 09 11:10:17 GMT 2024 - 5.6K bytes - Click Count (0) -
tests/test_dependency_wrapped.py
return True @noop_wrap def wrapped_gen_dependency() -> Generator[bool, None, None]: yield True @noop_wrap async def async_wrapped_dependency() -> bool: return True @noop_wrap async def async_wrapped_gen_dependency() -> AsyncGenerator[bool, None]: yield True @app.get("/wrapped-dependency/")
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Dec 17 21:25:59 GMT 2025 - 11.2K bytes - Click Count (0) -
docs/es/docs/tutorial/body.md
/// note | Nota FastAPI sabrá que el valor de `q` no es requerido debido al valor por defecto `= None`. El `str | None` (Python 3.10+) o `Union` en `Union[str, None]` (Python 3.9+) no es utilizado por FastAPI para determinar que el valor no es requerido, sabrá que no es requerido porque tiene un valor por defecto de `= None`.
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Dec 17 20:41:43 GMT 2025 - 7.6K bytes - Click Count (0) -
docs/ko/docs/tutorial/query-params-str-validations.md
기본값 `None`을 `Query(None)`으로 바꿔야 하므로, `Query`의 첫 번째 매개변수는 기본값을 정의하는 것과 같은 목적으로 사용됩니다. 그러므로: ```Python q: Optional[str] = Query(None) ``` ...위 코드는 아래와 동일하게 매개변수를 선택적으로 만듭니다: ```Python q: Optional[str] = None ``` 하지만 명시적으로 쿼리 매개변수를 선언합니다. /// info | 정보 FastAPI는 다음 부분에 관심이 있습니다: ```Python = None ``` 또는: ```Python = Query(None)
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Mon Nov 18 02:25:44 GMT 2024 - 9.2K bytes - Click Count (0) -
docs_src/python_types/tutorial009_py39.py
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Dec 17 20:41:43 GMT 2025 - 164 bytes - Click Count (0) -
docs_src/header_params/tutorial002_py310.py
from fastapi import FastAPI, Header app = FastAPI() @app.get("/items/") async def read_items( strange_header: str | None = Header(default=None, convert_underscores=False), ):
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Tue Mar 26 16:56:53 GMT 2024 - 228 bytes - Click Count (0)