[Zope-Checkins] CVS: ZODB3/ZODB - ConflictResolution.py:1.18.36.1

Tim Peters tim.one@comcast.net
Tue, 8 Jul 2003 18:14:26 -0400


Update of /cvs-repository/ZODB3/ZODB
In directory cvs.zope.org:/tmp/cvs-serv31889/ZODB

Modified Files:
      Tag: zodb33-devel-branch
	ConflictResolution.py 
Log Message:
tryToResolveConflict():  Since BTree nodes and Buckets are no longer
ExtensionClass instances, trying to create a new empty one via
__basic_new__ just blows up (AttributeError).  At least for those
specific types, we can use __new__ instead, and this repairs the 8
testSimpleConflict() failures.

For whatever persistent objects still are ExtensionClasses, I bet the
new code won't work, though (maybe this is one of those things that
needs a different metatype in order to work?).


=== ZODB3/ZODB/ConflictResolution.py 1.18 => 1.18.36.1 ===
--- ZODB3/ZODB/ConflictResolution.py:1.18	Mon Dec  9 17:31:19 2002
+++ ZODB3/ZODB/ConflictResolution.py	Tue Jul  8 18:14:21 2003
@@ -97,7 +97,7 @@
         klass = load_class(class_tuple)
         if klass is None:
             return None
-        inst = klass.__basicnew__()
+        inst = klass.__new__(klass)
 
         try:
             resolve = inst._p_resolveConflict