[Checkins] SVN: Products.ZopeVersionControl/trunk/ connection versions are no longer supported in ZODB 3.9

David Glick davidglick at onenw.org
Fri Jul 10 22:12:38 EDT 2009


Log message for revision 101804:
  connection versions are no longer supported in ZODB 3.9

Changed:
  U   Products.ZopeVersionControl/trunk/CHANGES.txt
  U   Products.ZopeVersionControl/trunk/Products/ZopeVersionControl/Utility.py

-=-
Modified: Products.ZopeVersionControl/trunk/CHANGES.txt
===================================================================
--- Products.ZopeVersionControl/trunk/CHANGES.txt	2009-07-11 02:10:26 UTC (rev 101803)
+++ Products.ZopeVersionControl/trunk/CHANGES.txt	2009-07-11 02:12:38 UTC (rev 101804)
@@ -4,6 +4,8 @@
 1.0a2 (unreleased)
 ------------------
 
+    - Don't break when checking the connection version in ZODB>=3.9.
+
     - Fixed tests to not use the DemoStorage quota parameter which was
       removed.
 

Modified: Products.ZopeVersionControl/trunk/Products/ZopeVersionControl/Utility.py
===================================================================
--- Products.ZopeVersionControl/trunk/Products/ZopeVersionControl/Utility.py	2009-07-11 02:10:26 UTC (rev 101803)
+++ Products.ZopeVersionControl/trunk/Products/ZopeVersionControl/Utility.py	2009-07-11 02:12:38 UTC (rev 101804)
@@ -14,10 +14,8 @@
 import os
 import time
 
-from AccessControl import ClassSecurityInfo
 from AccessControl import getSecurityManager
 from App.Common import package_home
-from DateTime import DateTime
 from App.class_init import default__class_init__ as InitializeClass
 from Persistence import Persistent
 from ZODB.TimeStamp import TimeStamp
@@ -130,7 +128,11 @@
     latest = mtime
     conn = object._p_jar
     load = conn._storage.load
-    version = conn._version
+    try:
+        version = conn._version
+    except AttributeError:
+        # ZODB 3.9+ compatibility
+        version = None
     refs = referencesf
 
     oids=[object._p_oid]



More information about the Checkins mailing list