[Zodb-checkins] SVN: ZODB/trunk/src/ Backed out an earlier change that tried to address

Jim Fulton jim at zope.com
Wed Aug 26 04:28:35 EDT 2009


Log message for revision 103217:
  Backed out an earlier change that tried to address
  https://bugs.launchpad.net/zodb/+bug/185066
  
  The fix didn't go far enough and a fix that would go far enough would
  be too risky this late in the 3.9 beta cycle.  This will probably need
  to wait till 3.10.
  

Changed:
  U   ZODB/trunk/src/CHANGES.txt
  U   ZODB/trunk/src/ZODB/serialize.py
  U   ZODB/trunk/src/ZODB/tests/testConnection.py

-=-
Modified: ZODB/trunk/src/CHANGES.txt
===================================================================
--- ZODB/trunk/src/CHANGES.txt	2009-08-26 08:05:36 UTC (rev 103216)
+++ ZODB/trunk/src/CHANGES.txt	2009-08-26 08:28:35 UTC (rev 103217)
@@ -19,9 +19,6 @@
 - Calling __setstate__ on a persistent object could under certain
   uncommon cause the process to crash.
 
-- Objects defining _p_deactivate methods that didn't call base methods
-  weren't loaded properly. https://bugs.launchpad.net/zodb/+bug/185066
-
 - When committing transactions involving blobs to ClientStorages with
   non-shared blob directories, a failure could occur in tpc_finish if
   there was insufficient disk space to copy the blob file or if the

Modified: ZODB/trunk/src/ZODB/serialize.py
===================================================================
--- ZODB/trunk/src/ZODB/serialize.py	2009-08-26 08:05:36 UTC (rev 103216)
+++ ZODB/trunk/src/ZODB/serialize.py	2009-08-26 08:28:35 UTC (rev 103217)
@@ -514,9 +514,9 @@
         obj._p_oid = oid
         obj._p_jar = self._conn
         # When an object is created, it is put in the UPTODATE
-        # state.  We must explicitly invalidate it to turn it into
+        # state.  We must explicitly deactivate it to turn it into
         # a ghost.
-        obj._p_invalidate()
+        obj._p_changed = None
 
         self._cache[oid] = obj
         return obj

Modified: ZODB/trunk/src/ZODB/tests/testConnection.py
===================================================================
--- ZODB/trunk/src/ZODB/tests/testConnection.py	2009-08-26 08:05:36 UTC (rev 103216)
+++ ZODB/trunk/src/ZODB/tests/testConnection.py	2009-08-26 08:28:35 UTC (rev 103217)
@@ -663,25 +663,10 @@
         self.assert_(cache.total_estimated_size >= 0)
 
 
-class class_that_ignores_deactivate(Persistent):
-    def _p_deactivate(self): pass
 
-def loading_objects_that_ignore_deactivate_bug_185066():
-    """See https://bugs.launchpad.net/bugs/185066
 
-    >>> db = ZODB.tests.util.DB()
-    >>> conn = db.open()
-    >>> conn.root.c = class_that_ignores_deactivate()
-    >>> conn.root.c.x = 1
-    >>> transaction.commit()
-    >>> conn2 = db.open()
-    >>> conn2.root.c.x
-    1
 
-    """
 
-
-
 # ---- stubs
 
 class StubObject(Persistent):



More information about the Zodb-checkins mailing list