- Sort Score
- Result 10 results
- Languages All
Results 581 - 590 of 1,058 for Fstr (0.03 sec)
-
tests/test_schema_ref_pydantic_v2.py
from inline_snapshot import snapshot from pydantic import BaseModel, ConfigDict, Field @pytest.fixture(name="client") def get_client(): app = FastAPI() class ModelWithRef(BaseModel): ref: str = Field(validation_alias="$ref", serialization_alias="$ref") model_config = ConfigDict(validate_by_alias=True, serialize_by_alias=True) @app.get("/", response_model=ModelWithRef) async def read_root() -> Any:
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Dec 20 15:55:38 UTC 2025 - 2.1K bytes - Viewed (0) -
docs_src/python_types/tutorial006_py39.py
def process_items(items: list[str]): for item in items:
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Fri Jan 07 14:11:31 UTC 2022 - 80 bytes - Viewed (0) -
docs/es/docs/tutorial/body-multiple-params.md
Como, por defecto, los valores singulares se interpretan como parámetros de query, no tienes que añadir explícitamente un `Query`, solo puedes hacer: ```Python q: Union[str, None] = None ``` O en Python 3.10 y superior: ```Python q: str | None = None ``` Por ejemplo: {* ../../docs_src/body_multiple_params/tutorial004_an_py310.py hl[28] *} /// info | Información
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Tue Dec 16 16:33:45 UTC 2025 - 5.2K bytes - Viewed (0) -
docs/ru/docs/tutorial/query-params.md
{* ../../docs_src/query_params/tutorial005_py39.py hl[6:7] *} Здесь параметр запроса `needy` является обязательным параметром с типом данных `str`. Если вы откроете в браузере URL-адрес, например: ``` http://127.0.0.1:8000/items/foo-item ``` ...без добавления обязательного параметра `needy`, вы увидите подобного рода ошибку: ```JSONRegistered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 20:41:43 UTC 2025 - 7.8K bytes - Viewed (0) -
schema/utils.go
"reflect" "regexp" "strings" "gorm.io/gorm/clause" "gorm.io/gorm/utils" ) var embeddedCacheKey = "embedded_cache_store" func ParseTagSetting(str string, sep string) map[string]string { settings := map[string]string{} names := strings.Split(str, sep) var parsedNames []string for i := 0; i < len(names); i++ { s := names[i] for strings.HasSuffix(s, "\\") && i+1 < len(names) { i++
Registered: Sun Dec 28 09:35:17 UTC 2025 - Last Modified: Thu Oct 30 11:15:36 UTC 2025 - 5.9K bytes - Viewed (0) -
docs/en/docs/tutorial/security/get-current-user.md
{* ../../docs_src/security/tutorial002_an_py310.py hl[25] *} ## Get the user { #get-the-user } `get_current_user` will use a (fake) utility function we created, that takes a token as a `str` and returns our Pydantic `User` model:Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sun Aug 31 09:15:41 UTC 2025 - 4K bytes - Viewed (0) -
docs/de/docs/tutorial/security/get-current-user.md
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Sep 20 15:10:09 UTC 2025 - 4.8K bytes - Viewed (0) -
docs/de/docs/index.md
from pydantic import BaseModel app = FastAPI() class Item(BaseModel): name: str price: float is_offer: Union[bool, None] = None @app.get("/") def read_root(): return {"Hello": "World"} @app.get("/items/{item_id}") def read_item(item_id: int, q: Union[str, None] = None): return {"item_id": item_id, "q": q} @app.put("/items/{item_id}")
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Fri Dec 26 09:39:53 UTC 2025 - 25.8K bytes - Viewed (0) -
docs_src/cookie_params/tutorial001_py39.py
from typing import Union from fastapi import Cookie, FastAPI app = FastAPI() @app.get("/items/") async def read_items(ads_id: Union[str, None] = Cookie(default=None)):
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 20:41:43 UTC 2025 - 202 bytes - Viewed (0) -
docs_src/header_params/tutorial001_py39.py
from typing import Union from fastapi import FastAPI, Header app = FastAPI() @app.get("/items/") async def read_items(user_agent: Union[str, None] = Header(default=None)):
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 20:41:43 UTC 2025 - 214 bytes - Viewed (0)