- Sort Score
- Result 10 results
- Languages All
Results 121 - 130 of 969 for resync (0.05 sec)
-
tests/test_http_connection_injection.py
from starlette.websockets import WebSocket app = FastAPI() app.state.value = 42 async def extract_value_from_http_connection(conn: HTTPConnection): return conn.app.state.value @app.get("/http") async def get_value_by_http(value: int = Depends(extract_value_from_http_connection)): return value @app.websocket("/ws") async def get_value_by_ws(
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Aug 09 13:56:41 UTC 2020 - 972 bytes - Viewed (0) -
docs_src/request_files/tutorial002.py
app = FastAPI() @app.post("/files/") async def create_files(files: List[bytes] = File()): return {"file_sizes": [len(file) for file in files]} @app.post("/uploadfiles/") async def create_upload_files(files: List[UploadFile]): return {"filenames": [file.filename for file in files]} @app.get("/") async def main(): content = """ <body>
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri May 13 23:38:22 UTC 2022 - 811 bytes - Viewed (0) -
docs_src/request_files/tutorial002_an_py39.py
app = FastAPI() @app.post("/files/") async def create_files(files: Annotated[list[bytes], File()]): return {"file_sizes": [len(file) for file in files]} @app.post("/uploadfiles/") async def create_upload_files(files: list[UploadFile]): return {"filenames": [file.filename for file in files]} @app.get("/") async def main(): content = """ <body>
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Mar 18 12:29:59 UTC 2023 - 826 bytes - Viewed (0) -
tests/scan_test.go
t.Errorf("Failed to scan to customized data type") } var resInt interface{} resInt = &User{} if err := DB.Table("users").Select("id, name, age").Where("id = ?", user3.ID).Find(&resInt).Error; err != nil { t.Fatalf("Failed to query with pointer of value, got error %v", err) } else if resInt.(*User).ID != user3.ID || resInt.(*User).Name != user3.Name || resInt.(*User).Age != user3.Age {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Wed Jun 12 10:57:36 UTC 2024 - 10.9K bytes - Viewed (0) -
cmd/local-locker_test.go
"math/rand" "testing" "time" "github.com/google/uuid" "github.com/minio/minio/internal/dsync" ) func TestLocalLockerExpire(t *testing.T) { wResources := make([]string, 1000) rResources := make([]string, 1000) quorum := 0 l := newLocker() ctx := context.Background() for i := range wResources { arg := dsync.LockArgs{ UID: mustGetUUID(), Resources: []string{mustGetUUID()}, Source: t.Name(),
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed Jul 24 10:24:01 UTC 2024 - 11.9K bytes - Viewed (0) -
tensorflow/c/eager/c_api_remote_test.cc
TestRemoteExecuteSilentCopiesOp(/*async=*/false, /*remote=*/true); } TEST(CAPI, RemoteExecuteSilentCopiesAsync) { TestRemoteExecuteSilentCopiesOp(/*async=*/true, /*remote=*/true); } TEST(CAPI, RemoteExecuteSilentCopiesLocal) { TestRemoteExecuteSilentCopiesOp(/*async=*/false, /*remote=*/false); } TEST(CAPI, RemoteExecuteSilentCopiesLocalAsync) { TestRemoteExecuteSilentCopiesOp(/*async=*/true, /*remote=*/false); }
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Wed Aug 12 00:14:22 UTC 2020 - 5.4K bytes - Viewed (0) -
tests/test_additional_responses_router.py
app = FastAPI() router = APIRouter() @router.get("/a", responses={501: {"description": "Error 1"}}) async def a(): return "a" @router.get( "/b", responses={ 502: {"description": "Error 2"}, "4XX": {"description": "Error with range, upper"}, }, ) async def b(): return "b" @router.get( "/c", responses={
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 5.1K bytes - Viewed (0) -
docs_src/generate_clients/tutorial003.py
async def create_item(item: Item): return {"message": "Item received"} @app.get("/items/", response_model=List[Item], tags=["items"]) async def get_items(): return [ {"name": "Plumbus", "price": 3}, {"name": "Portal Gun", "price": 9001}, ] @app.post("/users/", response_model=ResponseMessage, tags=["users"]) async def create_user(user: User):
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Mar 04 22:02:18 UTC 2022 - 939 bytes - Viewed (0) -
docs_src/bigger_applications/app/routers/items.py
responses={404: {"description": "Not found"}}, ) 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")
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Nov 29 17:32:18 UTC 2020 - 1011 bytes - Viewed (0) -
cmd/local-locker.go
// Unexpected inconsistency, delete. delete(l.lockUID, mapID) idx++ continue } reply = true l.removeEntry(resource, dsync.LockArgs{UID: args.UID}, &lris) idx++ } } } func (l *localLocker) Refresh(ctx context.Context, args dsync.LockArgs) (refreshed bool, err error) { select { case <-ctx.Done(): return false, ctx.Err() default: l.mutex.Lock()
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed Jul 24 10:24:01 UTC 2024 - 10.7K bytes - Viewed (0)