Skip to content

Commit

Permalink
Fix docstrings
Browse files Browse the repository at this point in the history
  • Loading branch information
gerlero committed Sep 23, 2024
1 parent cbdf671 commit 065ed61
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion foamlib/_cases/_util.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import functools
from types import TracebackType
from typing import Any, AsyncContextManager, Callable, Optional, Type

Expand All @@ -24,4 +25,8 @@ async def __aexit__(
def awaitableasynccontextmanager(
cm: Callable[..., "AsyncContextManager[Any]"],
) -> Callable[..., _AwaitableAsyncContextManager]:
return lambda *args, **kwargs: _AwaitableAsyncContextManager(cm(*args, **kwargs))
@functools.wraps(cm)
def f(*args: Any, **kwargs:Any) -> _AwaitableAsyncContextManager:
return _AwaitableAsyncContextManager(cm(*args, **kwargs))

return f

0 comments on commit 065ed61

Please sign in to comment.