- Sort Score
- Num 10 results
- Language All
Results 1 - 2 of 2 for CM (0.02 seconds)
-
fastapi/dependencies/utils.py
) -> Any: assert dependant.call if dependant.is_async_gen_callable: cm = asynccontextmanager(dependant.call)(**sub_values) elif dependant.is_gen_callable: cm = contextmanager_in_threadpool(contextmanager(dependant.call)(**sub_values)) return await stack.enter_async_context(cm) @dataclass class SolvedDependency: values: dict[str, Any] errors: list[Any]Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Sun Mar 15 11:44:39 GMT 2026 - 38.7K bytes - Click Count (3) -
fastapi/routing.py
""" Wraps a synchronous context manager to make it async. This is vendored from Starlette to avoid importing private symbols. """ def __init__(self, cm: AbstractContextManager[_T]) -> None: self._cm = cm async def __aenter__(self) -> _T: return self._cm.__enter__() async def __aexit__( self, exc_type: type[BaseException] | None,Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Sun Mar 15 11:44:39 GMT 2026 - 193K bytes - Click Count (0)