- Sort Score
- Result 10 results
- Languages All
Results 191 - 200 of 1,140 for rsync (0.03 sec)
-
docs_src/request_files/tutorial001_an_py39.py
from typing import Annotated from fastapi import FastAPI, File, UploadFile app = FastAPI() @app.post("/files/") async def create_file(file: Annotated[bytes, File()]): return {"file_size": len(file)} @app.post("/uploadfile/") async def create_upload_file(file: UploadFile):
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Mar 18 12:29:59 UTC 2023 - 322 bytes - Viewed (0) -
docs/zh/docs/tutorial/dependencies/index.md
/// ## 要不要使用 `async`? **FastAPI** 调用依赖项的方式与*路径操作函数*一样,因此,定义依赖项函数,也要应用与路径操作函数相同的规则。 即,既可以使用异步的 `async def`,也可以使用普通的 `def` 定义依赖项。 在普通的 `def` *路径操作函数*中,可以声明异步的 `async def` 依赖项;也可以在异步的 `async def` *路径操作函数*中声明普通的 `def` 依赖项。 上述这些操作都是可行的,**FastAPI** 知道该怎么处理。 /// note | "笔记" 如里不了解异步,请参阅[异步:*“着急了?”*](../../async.md){.internal-link target=_blank} 一章中 `async` 和 `await` 的内容。
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 7K bytes - Viewed (0) -
tests/test_filter_pydantic_sub_model/app_pv1.py
if not name.endswith("A"): raise ValueError("name must end in A") return name async def get_model_c() -> ModelC: return ModelC(username="test-user", password="test-password") @app.get("/model/{name}", response_model=ModelA) async def get_model_a(name: str, model_c=Depends(get_model_c)):
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jul 07 17:12:13 UTC 2023 - 784 bytes - Viewed (0) -
cmd/bucket-replication-handlers.go
// qualify for replication and re-sync the object(s) to target, provided ExistingObjectReplication is // enabled for the qualifying rule. This API is a MinIO only extension provided for situations where // remote target is entirely lost,and previously replicated objects need to be re-synced. If resync is // already in progress it returns an error
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Aug 15 12:04:40 UTC 2024 - 23.3K bytes - Viewed (0) -
docs_src/path_operation_configuration/tutorial002b.py
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Jan 23 17:43:04 UTC 2022 - 323 bytes - Viewed (0) -
docs_src/websockets/tutorial001.py
input.value = '' event.preventDefault() } </script> </body> </html> """ @app.get("/") async def get(): return HTMLResponse(html) @app.websocket("/ws") async def websocket_endpoint(websocket: WebSocket): await websocket.accept() while True: data = await websocket.receive_text()
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Thu Mar 26 19:09:53 UTC 2020 - 1.4K bytes - Viewed (0) -
docs_src/body_updates/tutorial002.py
"baz": {"name": "Baz", "description": None, "price": 50.2, "tax": 10.5, "tags": []}, } @app.get("/items/{item_id}", response_model=Item) async def read_item(item_id: str): return items[item_id] @app.patch("/items/{item_id}", response_model=Item) async def update_item(item_id: str, item: Item): stored_item_data = items[item_id] stored_item_model = Item(**stored_item_data)
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat May 14 11:59:59 UTC 2022 - 1K bytes - Viewed (0) -
docs_src/websockets/tutorial002_an_py310.py
input.value = '' event.preventDefault() } </script> </body> </html> """ @app.get("/") async def get(): return HTMLResponse(html) async def get_cookie_or_token( websocket: WebSocket, session: Annotated[str | None, Cookie()] = None, token: Annotated[str | None, Query()] = None, ):
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Mar 18 12:29:59 UTC 2023 - 2.8K bytes - Viewed (0) -
docs_src/websockets/tutorial002_py310.py
input.value = '' event.preventDefault() } </script> </body> </html> """ @app.get("/") async def get(): return HTMLResponse(html) async def get_cookie_or_token( websocket: WebSocket, session: str | None = Cookie(default=None), token: str | None = Query(default=None), ): if session is None and token is None:
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Mar 18 12:29:59 UTC 2023 - 2.7K bytes - Viewed (0) -
docs_src/path_operation_configuration/tutorial002_py310.py
tags: set[str] = set() @app.post("/items/", response_model=Item, tags=["items"]) async def create_item(item: Item): return item @app.get("/items/", tags=["items"]) async def read_items(): return [{"name": "Foo", "price": 42}] @app.get("/users/", tags=["users"]) async def read_users():
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jan 07 14:11:31 UTC 2022 - 537 bytes - Viewed (0)