File tree Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Original file line number Diff line number Diff line change 11from __future__ import annotations
22
3+ from contextlib import AbstractContextManager , AbstractAsyncContextManager
34from pathlib import Path
45from typing import (
56 Awaitable ,
@@ -465,6 +466,20 @@ class Resource(Provider[T]):
465466 ** kwargs : Injection ,
466467 ) -> None : ...
467468 @overload
469+ def __init__ (
470+ self ,
471+ provides : Optional [_Callable [..., AbstractContextManager [T ]]] = None ,
472+ * args : Injection ,
473+ ** kwargs : Injection ,
474+ ) -> None : ...
475+ @overload
476+ def __init__ (
477+ self ,
478+ provides : Optional [_Callable [..., AbstractAsyncContextManager [T ]]] = None ,
479+ * args : Injection ,
480+ ** kwargs : Injection ,
481+ ) -> None : ...
482+ @overload
468483 def __init__ (
469484 self ,
470485 provides : Optional [_Callable [..., _Iterator [T ]]] = None ,
You can’t perform that action at this time.
0 commit comments