We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c3a5619 commit 0c4350eCopy full SHA for 0c4350e
pymongo/asynchronous/mongo_client.py
@@ -2567,7 +2567,10 @@ async def run(self) -> T:
2567
try:
2568
if self._operation in (_Op.LIST_COLLECTIONS, _Op.INSERT):
2569
print(f"Retryable read for {self._operation}")
2570
- return await self._read() if self._is_read else await self._write()
+ res = await self._read() if self._is_read else await self._write()
2571
+ if self._operation in (_Op.LIST_COLLECTIONS, _Op.INSERT):
2572
+ print(f"Result for {self._operation}: {res}")
2573
+ return res
2574
except ServerSelectionTimeoutError:
2575
# The application may think the write was never attempted
2576
# if we raise ServerSelectionTimeoutError on the retry
0 commit comments