- Sort Score
- Result 10 results
- Languages All
Results 581 - 590 of 1,127 for def2 (0.03 sec)
-
docs/az/docs/index.md
app = FastAPI() @app.get("/") def read_root(): return {"Hello": "World"} @app.get("/items/{item_id}") def read_item(item_id: int, q: Union[str, None] = None): return {"item_id": item_id, "q": q} ``` <details markdown="1"> <summary>Və ya <code>async def</code>...</summary> Əgər kodunuzda `async` və ya `await` vardırsa `async def` istifadə edə bilərik: ```Python hl_lines="9 14"
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 20 19:20:23 UTC 2024 - 22.8K bytes - Viewed (0) -
tests/test_tutorial/test_response_model/test_tutorial003_01.py
from dirty_equals import IsDict, IsOneOf from fastapi.testclient import TestClient from docs_src.response_model.tutorial003_01 import app client = TestClient(app) def test_post_user(): response = client.post( "/user/", json={ "username": "foo", "password": "fighter", "email": "******@****.***", "full_name": "Grave Dohl", }, )
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Aug 04 20:47:07 UTC 2023 - 5.6K bytes - Viewed (0) -
tests/test_additional_responses_custom_validationerror.py
@app.get( "/a/{id}", response_class=JsonApiResponse, responses={422: {"description": "Error", "model": JsonApiError}}, ) async def a(id): pass # pragma: no cover client = TestClient(app) def test_openapi_schema(): response = client.get("/openapi.json") assert response.status_code == 200, response.text assert response.json() == { "openapi": "3.1.0",
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 2.9K bytes - Viewed (0) -
impl/maven-cli/src/main/java/org/apache/maven/cling/invoker/ProtoLogger.java
this.err = new PrintWriter(toPsOrDef(err, System.err), true); } private PrintStream toPsOrDef(OutputStream outputStream, PrintStream def) { if (outputStream == null) { return def; } if (outputStream instanceof PrintStream ps) { return ps; } return new PrintStream(outputStream); } //
Registered: Sun Nov 03 03:35:11 UTC 2024 - Last Modified: Fri Oct 25 12:31:46 UTC 2024 - 2.3K bytes - Viewed (0) -
tests/test_tutorial/test_extra_data_types/test_tutorial001_an.py
from dirty_equals import IsDict from fastapi.testclient import TestClient from docs_src.extra_data_types.tutorial001_an import app client = TestClient(app) def test_extra_types(): item_id = "ff97dd87-a4a5-4a12-b412-cde99f33e00e" data = { "start_datetime": "2018-12-22T14:00:00+00:00", "end_datetime": "2018-12-24T15:00:00+00:00", "repeat_at": "15:30:00", "process_after": 300, }
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Apr 19 00:11:40 UTC 2024 - 6.8K bytes - Viewed (0) -
tests/test_tutorial/test_extra_data_types/test_tutorial001.py
from dirty_equals import IsDict from fastapi.testclient import TestClient from docs_src.extra_data_types.tutorial001 import app client = TestClient(app) def test_extra_types(): item_id = "ff97dd87-a4a5-4a12-b412-cde99f33e00e" data = { "start_datetime": "2018-12-22T14:00:00+00:00", "end_datetime": "2018-12-24T15:00:00+00:00", "repeat_at": "15:30:00", "process_after": 300, }
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Apr 19 00:11:40 UTC 2024 - 6.8K bytes - Viewed (0) -
tests/test_tutorial/test_path_operation_configurations/test_tutorial005.py
client = TestClient(app) def test_query_params_str_validations(): response = client.post("/items/", json={"name": "Foo", "price": 42}) assert response.status_code == 200, response.text assert response.json() == { "name": "Foo", "price": 42, "description": None, "tax": None, "tags": [], } @needs_pydanticv2 def test_openapi_schema():
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Thu Sep 28 04:14:40 UTC 2023 - 8.7K bytes - Viewed (0) -
tensorflow/c/eager/c_api_remote_test_util.cc
" }" " }" " ret {" " key: 'm'" " value: 'matmul:product'" " }"), &def)); return def.SerializeAsString(); } void TestRemoteExecuteSilentCopies(bool async, bool remote, bool func, bool heavy_load_on_streaming_rpc,
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Fri Dec 11 22:56:03 UTC 2020 - 9.1K bytes - Viewed (0) -
docs/pl/docs/index.md
app = FastAPI() @app.get("/") def read_root(): return {"Hello": "World"} @app.get("/items/{item_id}") def read_item(item_id: int, q: Union[str, None] = None): return {"item_id": item_id, "q": q} ``` <details markdown="1"> <summary>Albo użyj <code>async def</code>...</summary> Jeżeli twój kod korzysta z `async` / `await`, użyj `async def`: ```Python hl_lines="9 14"
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 20 19:20:23 UTC 2024 - 19.3K bytes - Viewed (0) -
docs/ru/docs/tutorial/dependencies/index.md
Вы можете использовать `async def` или обычное `def`. Вы также можете объявить зависимости с `async def` внутри обычной `def` *функции обработки пути*, или `def` зависимости внутри `async def` *функции обработки пути*, и так далее. Это всё не важно. **FastAPI** знает, что нужно сделать. 😎 /// note | "Информация"
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 17.6K bytes - Viewed (0)