Skip to content

Commit 5852bd8

Browse files
authored
Change with_transaction callback return type to Awaitable
1 parent 6a796c8 commit 5852bd8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pymongo/asynchronous/client_session.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -143,8 +143,8 @@
143143
TYPE_CHECKING,
144144
Any,
145145
AsyncContextManager,
146+
Awaitable,
146147
Callable,
147-
Coroutine,
148148
Mapping,
149149
MutableMapping,
150150
NoReturn,
@@ -604,7 +604,7 @@ def _inherit_option(self, name: str, val: _T) -> _T:
604604

605605
async def with_transaction(
606606
self,
607-
callback: Callable[[AsyncClientSession], Coroutine[Any, Any, _T]],
607+
callback: Callable[[AsyncClientSession], Awaitable[_T]],
608608
read_concern: Optional[ReadConcern] = None,
609609
write_concern: Optional[WriteConcern] = None,
610610
read_preference: Optional[_ServerMode] = None,

0 commit comments

Comments
 (0)