Skip to content

Commit 92eafbf

Browse files
committed
testing
1 parent adcc11d commit 92eafbf

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

pymongo/asynchronous/mongo_client.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2579,6 +2579,8 @@ async def run(self) -> T:
25792579
# A ServerSelectionTimeoutError error indicates that there may
25802580
# be a persistent outage. Attempting to retry in this case will
25812581
# most likely be a waste of time.
2582+
if self._operation in (_Op.LIST_COLLECTIONS, _Op.INSERT):
2583+
print(f"Raising timeout error for {self._operation}")
25822584
raise
25832585
except PyMongoError as exc:
25842586
if self._operation in (_Op.LIST_COLLECTIONS, _Op.INSERT):
@@ -2619,6 +2621,8 @@ async def run(self) -> T:
26192621
await self._session._unpin()
26202622
if not retryable_write_error_exc or self._is_not_eligible_for_retry():
26212623
if exc.has_error_label("NoWritesPerformed") and self._last_error:
2624+
if self._operation in (_Op.LIST_COLLECTIONS, _Op.INSERT):
2625+
print(f"Raising error for {self._operation}")
26222626
raise self._last_error from exc
26232627
else:
26242628
if self._operation in (_Op.LIST_COLLECTIONS, _Op.INSERT):

0 commit comments

Comments
 (0)