[Zodb-checkins] CVS: ZODB3/ZEO - ClientStorage.py:1.61
Guido van Rossum
guido@python.org
Wed, 18 Sep 2002 17:17:49 -0400
Update of /cvs-repository/ZODB3/ZEO
In directory cvs.zope.org:/tmp/cvs-serv32763
Modified Files:
ClientStorage.py
Log Message:
Fix a mysterious Windows hang: checkReconnectSwitch() would fail.
The fix is to change testConnection() to only retry the register()
call with the read-only flag set when we're not alrady connected.
But I don't understand why this fix is needed; I'll keep debugging.
=== ZODB3/ZEO/ClientStorage.py 1.60 => 1.61 ===
--- ZODB3/ZEO/ClientStorage.py:1.60 Tue Sep 17 13:06:29 2002
+++ ZODB3/ZEO/ClientStorage.py Wed Sep 18 17:17:48 2002
@@ -199,7 +199,7 @@
stub.register(str(self._storage), self._is_read_only)
return (stub, 1)
except POSException.ReadOnlyError:
- if not self._read_only_fallback:
+ if not self._read_only_fallback or self.is_connected():
raise
log2(INFO, "Got ReadOnlyError; trying again with read_only=1")
stub.register(str(self._storage), read_only=1)