- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 414 for fare (0.15 sec)
-
docs_src/bigger_applications/app/routers/items.py
) fake_items_db = {"plumbus": {"name": "Plumbus"}, "gun": {"name": "Portal Gun"}} @router.get("/") async def read_items(): return fake_items_db @router.get("/{item_id}") async def read_item(item_id: str): if item_id not in fake_items_db: raise HTTPException(status_code=404, detail="Item not found") return {"name": fake_items_db[item_id]["name"], "item_id": item_id}
Python - Registered: Sun Apr 28 07:19:10 GMT 2024 - Last Modified: Sun Nov 29 17:32:18 GMT 2020 - 1011 bytes - Viewed (0) -
docs_src/extra_models/tutorial002_py310.py
password: str class UserOut(UserBase): pass class UserInDB(UserBase): hashed_password: str def fake_password_hasher(raw_password: str): return "supersecret" + raw_password def fake_save_user(user_in: UserIn): hashed_password = fake_password_hasher(user_in.password) user_in_db = UserInDB(**user_in.dict(), hashed_password=hashed_password) print("User saved! ..not really")
Python - Registered: Sun Apr 28 07:19:10 GMT 2024 - Last Modified: Fri Jan 07 14:11:31 GMT 2022 - 792 bytes - Viewed (0) -
docs_src/extra_models/tutorial002.py
password: str class UserOut(UserBase): pass class UserInDB(UserBase): hashed_password: str def fake_password_hasher(raw_password: str): return "supersecret" + raw_password def fake_save_user(user_in: UserIn): hashed_password = fake_password_hasher(user_in.password) user_in_db = UserInDB(**user_in.dict(), hashed_password=hashed_password) print("User saved! ..not really")
Python - Registered: Sun Apr 28 07:19:10 GMT 2024 - Last Modified: Sat May 14 11:59:59 GMT 2022 - 824 bytes - Viewed (0) -
tests/test_tutorial/test_custom_response/test_tutorial007.py
from fastapi.testclient import TestClient from docs_src.custom_response.tutorial007 import app client = TestClient(app) def test_get(): fake_content = b"some fake video bytes" response = client.get("/")
Python - Registered: Sun Apr 28 07:19:10 GMT 2024 - Last Modified: Thu Jul 09 18:06:12 GMT 2020 - 264 bytes - Viewed (0) -
docs_src/security/tutorial004_an_py39.py
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): user = get_user(fake_db, username) if not user: return False if not verify_password(password, user.hashed_password): return False return user
Python - Registered: Sun Apr 28 07:19:10 GMT 2024 - Last Modified: Tue Mar 26 16:56:53 GMT 2024 - 4.1K bytes - Viewed (0) -
docs_src/security/tutorial004.py
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): user = get_user(fake_db, username) if not user: return False if not verify_password(password, user.hashed_password): return False return user
Python - Registered: Sun Apr 28 07:19:10 GMT 2024 - Last Modified: Tue Mar 26 16:56:53 GMT 2024 - 4K bytes - Viewed (0) -
docs_src/security/tutorial004_an.py
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): user = get_user(fake_db, username) if not user: return False if not verify_password(password, user.hashed_password): return False return user
Python - Registered: Sun Apr 28 07:19:10 GMT 2024 - Last Modified: Tue Mar 26 16:56:53 GMT 2024 - 4.1K bytes - Viewed (0) -
docs/assets/css/app.css
@font-face { font-family: cash-market; src: url("https://cash-f.squarecdn.com/static/fonts/cash-market/v2/CashMarket-Regular.woff2") format("woff2"); font-weight: 400; font-style: normal } @font-face { font-family: cash-market; src: url("https://cash-f.squarecdn.com/static/fonts/cash-market/v2/CashMarket-Medium.woff2") format("woff2"); font-weight: 500; font-style: normal } @font-face {
CSS - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Tue Feb 08 07:57:03 GMT 2022 - 1.1K bytes - Viewed (4) -
tests/test_tutorial/test_dependencies/test_tutorial012.py
response = client.get( "/items/", headers={"X-Token": "fake-super-secret-token", "X-Key": "invalid"} ) assert response.status_code == 400, response.text assert response.json() == {"detail": "X-Key header invalid"} def test_get_invalid_second_header_users(): response = client.get( "/users/", headers={"X-Token": "fake-super-secret-token", "X-Key": "invalid"} )
Python - Registered: Sun Apr 28 07:19:10 GMT 2024 - Last Modified: Thu Apr 18 19:40:57 GMT 2024 - 8.4K bytes - Viewed (0) -
finisher_api.go
// db.Where(User{Name: "non_existing"}).Attrs(User{Email: "fake@fake.org"}).FirstOrInit(&user) // // user -> User{Name: "non_existing", Email: "fake@fake.org"} // // // assign email regardless of if record is found // db.Where(User{Name: "jinzhu"}).Assign(User{Email: "fake@fake.org"}).FirstOrInit(&user) // // user -> User{Name: "jinzhu", Age: 20, Email: "fake@fake.org"}
Go - Registered: Sun Apr 28 09:35:09 GMT 2024 - Last Modified: Fri Jan 12 08:42:21 GMT 2024 - 22.7K bytes - Viewed (0)