- Sort Score
- Result 10 results
- Languages All
Results 141 - 150 of 672 for paso (0.02 sec)
-
tests/test_param_in_path_and_dependency.py
app = FastAPI() async def user_exists(user_id: int): return True @app.get("/users/{user_id}", dependencies=[Depends(user_exists)]) async def read_users(user_id: int): pass client = TestClient(app) def test_read_users(): response = client.get("/users/42") assert response.status_code == 200, response.text def test_openapi_schema():
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 3.1K bytes - Viewed (0) -
tests/test_additional_properties_bool.py
from fastapi.testclient import TestClient from pydantic import BaseModel, ConfigDict class FooBaseModel(BaseModel): model_config = ConfigDict(extra="forbid") class Foo(FooBaseModel): pass app = FastAPI() @app.post("/") async def post( foo: Union[Foo, None] = None, ): return foo client = TestClient(app) def test_call_invalid():
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Dec 27 18:19:10 UTC 2025 - 3.7K bytes - Viewed (0) -
docs/en/docs/reference/security/index.md
# Security Tools When you need to declare dependencies with OAuth2 scopes you use `Security()`. But you still need to define what is the dependable, the callable that you pass as a parameter to `Depends()` or `Security()`. There are multiple tools that you can use to create those dependables, and they get integrated into OpenAPI so they are shown in the automatic docs UI, they can be used by automatically generated clients and SDKs, etc.
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Thu Apr 18 19:53:19 UTC 2024 - 1.6K bytes - Viewed (0) -
docs_src/openapi_callbacks/tutorial001_py310.py
invoices_callback_router = APIRouter() @invoices_callback_router.post( "{$callback_url}/invoices/{$request.body.id}", response_model=InvoiceEventReceived ) def invoice_notification(body: InvoiceEvent): pass @app.post("/invoices/", callbacks=invoices_callback_router.routes) def create_invoice(invoice: Invoice, callback_url: HttpUrl | None = None): """ Create an invoice.
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 10 08:55:32 UTC 2025 - 1.3K bytes - Viewed (0) -
tests/test_sub_callbacks.py
) def invoice_notification(body: InvoiceEvent): pass # pragma: nocover class Event(BaseModel): name: str total: float events_callback_router = APIRouter() @events_callback_router.get("{$callback_url}/events/{$request.body.title}") def event_callback(event: Event): pass # pragma: nocover subrouter = APIRouter()
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Dec 27 18:19:10 UTC 2025 - 12.9K bytes - Viewed (0) -
docs/fr/docs/tutorial/background-tasks.md
## Avertissement
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Oct 11 17:48:49 UTC 2025 - 5.5K bytes - Viewed (0) -
android/guava/src/com/google/common/escape/Platform.java
return requireNonNull(DEST_TL.get()); } /** * A thread-local destination buffer to keep us from creating new buffers. The starting size is * 1024 characters. If we grow past this we don't put it back in the threadlocal, we just keep * going and grow as needed. */ private static final ThreadLocal<char[]> DEST_TL = new ThreadLocal<char[]>() { @Override
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Thu Aug 07 16:05:33 UTC 2025 - 1.5K bytes - Viewed (0) -
tests/test_dependency_after_yield_websockets.py
assert data == "baz" def test_websocket_dependency_after_yield_broken(): with pytest.raises(ValueError, match="Session closed"): with client.websocket_connect("/ws-broken"):
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 21:25:59 UTC 2025 - 2K bytes - Viewed (0) -
docs/fr/docs/features.md
### Faite en python moderne Tout est basé sur la déclaration de type standard de **Python 3.8** (grâce à Pydantic). Pas de nouvelles syntaxes à apprendre. Juste du Python standard et moderne. Si vous souhaitez un rappel de 2 minutes sur l'utilisation des types en Python (même si vous ne comptez pas utiliser FastAPI), jetez un oeil au tutoriel suivant: [Python Types](python-types.md){.internal-link target=_blank}.
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Oct 11 17:48:49 UTC 2025 - 11.1K bytes - Viewed (0) -
docs/en/docs/tutorial/background-tasks.md
{* ../../docs_src/background_tasks/tutorial001_py39.py hl[1,13] *} **FastAPI** will create the object of type `BackgroundTasks` for you and pass it as that parameter. ## Create a task function { #create-a-task-function } Create a function to be run as the background task. It is just a standard function that can receive parameters.Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 20:41:43 UTC 2025 - 4.8K bytes - Viewed (0)