Skip to content

Commit ac8b382

Browse files
committed
continue to raise AutoReconnect if some hosts are potential candidates, but can't be reached
1 parent 78959c3 commit ac8b382

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

pymongo/replica_set_connection.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -527,6 +527,8 @@ def refresh(self):
527527
self.__hosts = hosts
528528
break
529529
else:
530+
if errors:
531+
raise AutoReconnect(', '.join(errors))
530532
raise ConfigurationError('No suitable hosts found')
531533

532534
self.__update_pools()

0 commit comments

Comments
 (0)