- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 31 for confirm (0.19 sec)
-
docs_src/settings/app02_an_py39/main.py
from functools import lru_cache from typing import Annotated from fastapi import Depends, FastAPI from .config import Settings app = FastAPI() @lru_cache def get_settings(): return Settings() @app.get("/info") async def info(settings: Annotated[Settings, Depends(get_settings)]): return { "app_name": settings.app_name, "admin_email": settings.admin_email,
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Tue Oct 24 20:26:06 GMT 2023 - 445 bytes - Viewed (0) -
docs_src/schema_extra_example/tutorial001_py310.py
from fastapi import FastAPI from pydantic import BaseModel app = FastAPI() class Item(BaseModel): name: str description: str | None = None price: float tax: float | None = None model_config = { "json_schema_extra": { "examples": [ { "name": "Foo", "description": "A very nice Item", "price": 35.4,
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Fri Jul 07 17:12:13 GMT 2023 - 646 bytes - Viewed (0) -
docs_src/schema_extra_example/tutorial001_pv1.py
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Fri Jul 07 17:12:13 GMT 2023 - 669 bytes - Viewed (0) -
.github/actions/people/app/main.py
github_sponsors_path.write_text(new_github_sponsors_content, encoding="utf-8") logging.info("Setting up GitHub Actions git user") subprocess.run(["git", "config", "user.name", "github-actions"], check=True) subprocess.run( ["git", "config", "user.email", "******@****.***"], check=True ) branch_name = "fastapi-people" logging.info(f"Creating a new branch {branch_name}")
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Tue Mar 26 17:38:21 GMT 2024 - 19.2K bytes - Viewed (1) -
tests/test_schema_extra_examples.py
def create_app(): app = FastAPI() class Item(BaseModel): data: str if PYDANTIC_V2: model_config = ConfigDict( json_schema_extra={"example": {"data": "Data in schema_extra"}} ) else: class Config: schema_extra = {"example": {"data": "Data in schema_extra"}} @app.post("/schema_extra/") def schema_extra(item: Item):
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Tue Oct 24 20:26:06 GMT 2023 - 37.7K bytes - Viewed (0) -
.github/actions/notify-translations/app/main.py
if __name__ == "__main__": settings = Settings() if settings.input_debug: logging.basicConfig(level=logging.DEBUG) else: logging.basicConfig(level=logging.INFO) logging.debug(f"Using config: {settings.json()}") g = Github(settings.input_token.get_secret_value()) repo = g.get_repo(settings.github_repository) if not settings.github_event_path.is_file(): raise RuntimeError(
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Wed Sep 27 23:01:46 GMT 2023 - 12.4K bytes - Viewed (0) -
docs_src/settings/app02/config.py
Sebastián RamÃrez <******@****.***> 1688749933 +0200
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Fri Jul 07 17:12:13 GMT 2023 - 159 bytes - Viewed (0) -
scripts/docs.py
config["extra"]["alternate"] = new_alternate return config def update_config() -> None: config = get_updated_config_content() en_config_path.write_text( yaml.dump(config, sort_keys=False, width=200, allow_unicode=True), encoding="utf-8", ) @app.command() def verify_config() -> None: """
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Mon Jan 22 19:26:14 GMT 2024 - 10.9K bytes - Viewed (1) -
tests/test_jsonable_encoder.py
class RoleEnum(Enum): admin = "admin" normal = "normal" class ModelWithConfig(BaseModel): role: Optional[RoleEnum] = None if PYDANTIC_V2: model_config = {"use_enum_values": True} else: class Config: use_enum_values = True class ModelWithAlias(BaseModel): foo: str = Field(alias="Foo") class ModelWithDefault(BaseModel):
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Thu Apr 18 21:56:59 GMT 2024 - 9K bytes - Viewed (0) -
docs_src/settings/app03_an/main.py
from functools import lru_cache from typing import Annotated from fastapi import Depends, FastAPI from . import config app = FastAPI() @lru_cache def get_settings(): return config.Settings() @app.get("/info") async def info(settings: Annotated[config.Settings, Depends(get_settings)]): return { "app_name": settings.app_name, "admin_email": settings.admin_email,
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Tue Oct 24 20:26:06 GMT 2023 - 451 bytes - Viewed (0)