- Sort Score
- Result 10 results
- Languages All
Results 61 - 70 of 907 for fdef (0.04 sec)
-
docs_src/security/tutorial005_py39.py
) app = FastAPI() def verify_password(plain_password, hashed_password): return pwd_context.verify(plain_password, hashed_password) def get_password_hash(password): return pwd_context.hash(password) def get_user(db, username: str): if username in db: user_dict = db[username] return UserInDB(**user_dict) def authenticate_user(fake_db, username: str, password: str):
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Mon May 20 17:37:28 UTC 2024 - 5.2K bytes - Viewed (0) -
bin/diff_yaml.py
import sys import yaml # pyyaml # returns fully qualified resource name of the k8s resource def by_resource_name(res): if res is None: return "" return "{}::{}::{}".format(res['apiVersion'], res['kind'], res['metadata']['name']) def keydiff(k0, k1): k0s = set(k0) k1s = set(k1) added = k1s - k0s removed = k0s - k1s
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Wed Mar 03 16:14:57 UTC 2021 - 4.5K bytes - Viewed (0) -
docs/em/docs/async.md
### ๐ง-๐ ๐ ๐ช โ๏ธ ๐ ๐ & [๐ง-๐](tutorial/dependencies/sub-dependencies.md){.internal-link target=_blank} ๐ซ ๐ ๐ (๐ข ๐ข ๐), ๐ซ ๐ช โ โฎ๏ธ `async def` & โฎ๏ธ ๐ `def`. โซ๏ธ ๐ ๐ท, & ๐ โ โฎ๏ธ ๐ `def` ๐ ๐ค ๐ ๐ข ๐งต (โช๏ธโก๏ธ ๐งต) โฉ๏ธ โ "โ". ### ๐ ๐ ๐ข ๐ ๐ ๐ ๐ข ๐ ๐ ๐ค ๐ ๐ช โ โฎ๏ธ ๐ `def` โ๏ธ `async def` & FastAPI ๐ ๐ซ ๐ ๐ ๐ ๐ค โซ๏ธ.
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Tue Aug 06 04:48:30 UTC 2024 - 18.7K bytes - Viewed (0) -
docs_src/sql_databases/tutorial002_an_py39.py
engine = create_engine(sqlite_url, connect_args=connect_args) def create_db_and_tables(): SQLModel.metadata.create_all(engine) def get_session(): with Session(engine) as session: yield session SessionDep = Annotated[Session, Depends(get_session)] app = FastAPI() @app.on_event("startup") def on_startup(): create_db_and_tables()
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Wed Oct 09 19:44:42 UTC 2024 - 2.5K bytes - Viewed (0) -
scripts/docs.py
build_site_path = Path("site_build").absolute() @lru_cache def is_mkdocs_insiders() -> bool: version = metadata.version("mkdocs-material") return "insiders" in version def get_en_config() -> Dict[str, Any]: return mkdocs.utils.yaml_load(en_config_path.read_text(encoding="utf-8")) def get_lang_paths() -> List[Path]: return sorted(docs_path.iterdir()) def lang_callback(lang: Optional[str]) -> Union[str, None]:
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Tue Oct 08 11:01:17 UTC 2024 - 13.5K bytes - Viewed (0) -
docs_src/sql_databases/tutorial001_an.py
engine = create_engine(sqlite_url, connect_args=connect_args) def create_db_and_tables(): SQLModel.metadata.create_all(engine) def get_session(): with Session(engine) as session: yield session SessionDep = Annotated[Session, Depends(get_session)] app = FastAPI() @app.on_event("startup") def on_startup(): create_db_and_tables() @app.post("/heroes/")
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Wed Oct 09 19:44:42 UTC 2024 - 1.8K bytes - Viewed (0) -
tests/test_dependency_normal_exceptions.py
state = initial_state.copy() app = FastAPI() async def get_database(): temp_database = fake_database.copy() try: yield temp_database fake_database.update(temp_database) except HTTPException: state["except"] = True raise finally: state["finally"] = True @app.put("/invalid-user/{user_id}") def put_invalid_user(
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Feb 24 23:06:37 UTC 2024 - 1.9K bytes - Viewed (0) -
build-logic/documentation/src/test/groovy/gradlebuild/docs/XmlSpecification.groovy
} def formatTree(Closure cl) { withCategories { return formatTree(cl.call()) } } def withCategories(Closure cl) { use(BuildableDOMCategory) { return cl.call() } } def format(Node... nodes) { format(nodes as List) } def formatTree(Node... nodes) { formatTree(nodes as List)
Registered: Wed Nov 06 11:36:14 UTC 2024 - Last Modified: Wed Dec 09 08:14:05 UTC 2020 - 4.1K bytes - Viewed (0) -
build-logic/documentation/src/test/groovy/gradlebuild/docs/model/SimpleClassMetaDataRepositoryTest.groovy
def canAddMetaData() { TestDomainObject value = new TestDomainObject('a') when: repository.put('class', value) then: repository.find('class') == value repository.get('class') == value } def findReturnsNullForUnknownClass() { expect: repository.find('unknown') == null
Registered: Wed Nov 06 11:36:14 UTC 2024 - Last Modified: Sat Apr 06 02:21:33 UTC 2024 - 3.8K bytes - Viewed (0) -
tests/test_read_with_orm_mode.py
from pydantic import BaseModel, ConfigDict from .utils import needs_pydanticv1, needs_pydanticv2 @needs_pydanticv2 def test_read_with_orm_mode() -> None: class PersonBase(BaseModel): name: str lastname: str class Person(PersonBase): @property def full_name(self) -> str: return f"{self.name} {self.lastname}" model_config = ConfigDict(from_attributes=True)
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jul 07 17:12:13 UTC 2023 - 2.4K bytes - Viewed (0)