- Sort Score
- Num 10 results
- Language All
Results 1 - 10 of 295 for works (0.02 seconds)
-
fastapi/concurrency.py
# has its own internal pool (e.g. a database connection pool) # to avoid this we let __exit__ run without a capacity limit # since we're creating a new limiter for each call, any non-zero limit # works (1 is arbitrary) exit_limiter = CapacityLimiter(1) try: yield await run_in_threadpool(cm.__enter__) except Exception as e: ok = bool( await anyio.to_thread.run_sync(
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Dec 17 21:25:59 GMT 2025 - 1.5K bytes - Click Count (0) -
tests/test_inherited_custom_class.py
@field_serializer("a_uuid") def serialize_a_uuid(self, v): return str(v) @app.get("/get_custom_class") def return_some_user(): # Test that the fix also works for custom pydantic classes return SomeCustomClass(a_uuid=MyUuid("b8799909-f914-42de-91bc-95c819218d01")) client = TestClient(app) with client: response_simple = client.get("/fast_uuid")Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Sat Dec 27 12:54:56 GMT 2025 - 1.8K bytes - Click Count (0) -
impl/maven-core/src/test/java/org/apache/maven/configuration/internal/EnhancedCompositeBeanHelperTest.java
import static org.mockito.Mockito.mock; import static org.mockito.Mockito.verify; import static org.mockito.Mockito.when; /** * Test for EnhancedCompositeBeanHelper to ensure it works correctly and provides performance benefits. */ class EnhancedCompositeBeanHelperTest { private EnhancedCompositeBeanHelper helper; private ConverterLookup converterLookup;Created: Sun Dec 28 03:35:09 GMT 2025 - Last Modified: Wed Nov 12 14:59:46 GMT 2025 - 8.7K bytes - Click Count (0) -
docs_src/schema_extra_example/tutorial005_py39.py
async def update_item( *, item_id: int, item: Item = Body( openapi_examples={ "normal": { "summary": "A normal example", "description": "A **normal** item works correctly.", "value": { "name": "Foo", "description": "A very nice Item", "price": 35.4, "tax": 3.2, },
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Dec 17 20:41:43 GMT 2025 - 1.4K bytes - Click Count (0) -
docs/en/docs/how-to/migrate-from-pydantic-v1-to-pydantic-v2.md
### Migrate in steps { #migrate-in-steps } /// tip First try with `bump-pydantic`, if your tests pass and that works, then you're done in one command. ✨ /// If `bump-pydantic` doesn't work for your use case, you can use the support for both Pydantic v1 and v2 models in the same app to do the migration to Pydantic v2 gradually.Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Sat Dec 20 15:55:38 GMT 2025 - 5.5K bytes - Click Count (0) -
docs/en/docs/tutorial/bigger-applications.md
{* ../../docs_src/bigger_applications/app_an_py39/routers/items.py hl[3] title["app/routers/items.py"] *} #### How relative imports work { #how-relative-imports-work } /// tip If you know perfectly how imports work, continue to the next section below. /// A single dot `.`, like in: ```Python from .dependencies import get_token_header ``` would mean:Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Dec 10 08:55:32 GMT 2025 - 18.6K bytes - Click Count (0) -
docs/en/docs/features.md
`FastAPI` is actually a sub-class of `Starlette`. So, if you already know or use Starlette, most of the functionality will work the same way. With **FastAPI** you get all of **Starlette**'s features (as FastAPI is just Starlette on steroids):
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Sat Oct 11 17:48:49 GMT 2025 - 9.5K bytes - Click Count (0) -
tests/test_tutorial/test_schema_extra_example/test_tutorial005.py
"normal": { "summary": "A normal example", "description": "A **normal** item works correctly.", "value": { "name": "Foo", "description": "A very nice Item",
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Sat Dec 27 18:19:10 GMT 2025 - 6.1K bytes - Click Count (0) -
docs/en/docs/how-to/custom-docs-ui-assets.md
Swagger UI will handle it behind the scenes for you, but it needs this "redirect" helper. /// ### Create a *path operation* to test it { #create-a-path-operation-to-test-it } Now, to be able to test that everything works, create a *path operation*: {* ../../docs_src/custom_docs_ui/tutorial001_py39.py hl[36:38] *} ### Test it { #test-it }
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Dec 17 20:41:43 GMT 2025 - 7.8K bytes - Click Count (0) -
internal/dsync/drwmutex_test.go
mu := NewDRWMutex(ds, "test-unlock-panic-2") defer func() { if recover() == nil { t.Fatalf("unlock of unlocked RWMutex did not panic") } mu.RUnlock(t.Context()) // Unlock, so -test.count > 1 works }() mu.RLock(id, source) mu.Unlock(t.Context()) } // Borrowed from rwmutex_test.go func TestRUnlockPanic(t *testing.T) { defer func() { if recover() == nil {
Created: Sun Dec 28 19:28:13 GMT 2025 - Last Modified: Sun Sep 28 20:59:21 GMT 2025 - 9.4K bytes - Click Count (0)