Commit 374c7e96 authored by Guido van Rossum's avatar Guido van Rossum

In checkReconnectSwitch(), during the switch, _dostore() can fail with

a variety of exceptions.  Catch all of them.  (The only ones I've seen
are Disconnected and ReadOnlyError, but since we're disconnected
abruptly as part of the switch, it's possible to see any of the
exceptions that checkReconnection() catches.)
parent 20693649
...@@ -508,7 +508,8 @@ class ConnectionTests(StorageTestBase.StorageTestBase): ...@@ -508,7 +508,8 @@ class ConnectionTests(StorageTestBase.StorageTestBase):
try: try:
self._dostore() self._dostore()
break break
except ReadOnlyError: except (Disconnected, ReadOnlyError,
select.error, thread.error, socket.error):
time.sleep(0.1) time.sleep(0.1)
else: else:
self.fail("Couldn't store after starting a read-write server") self.fail("Couldn't store after starting a read-write server")
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment