[Zope-CVS] CVS: Products/Ape/lib/apelib/sql - classification.py:1.5.4.3

Shane Hathaway shane at zope.com
Thu Dec 25 23:23:04 EST 2003


Update of /cvs-repository/Products/Ape/lib/apelib/sql
In directory cvs.zope.org:/tmp/cvs-serv7640/lib/apelib/sql

Modified Files:
      Tag: ape-0_8-branch
	classification.py 
Log Message:
Renamed ConflictError to OIDConflictError.

ZODB conflict errors are related to high load and can be solved by
improving capacity.  OID conflicts, OTOH, are really programming errors.
They indicate that someone is trying to write different objects for 
a single OID.


=== Products/Ape/lib/apelib/sql/classification.py 1.5.4.2 => 1.5.4.3 ===
--- Products/Ape/lib/apelib/sql/classification.py:1.5.4.2	Tue Dec 23 00:52:36 2003
+++ Products/Ape/lib/apelib/sql/classification.py	Thu Dec 25 23:22:33 2003
@@ -17,7 +17,7 @@
 """
 
 from apelib.core.schemas import FieldSchema
-from apelib.core.interfaces import ConflictError
+from apelib.core.interfaces import OIDConflictError
 from sqlbase import SQLGatewayBase
 
 
@@ -51,7 +51,7 @@
         items = self.execute(event, 'read', 1, oid=event.oid)
         if items and event.is_new:
             # Something is already stored at this OID.
-            raise ConflictError(event.oid)
+            raise OIDConflictError(event.oid)
         cn = classification.get('class_name', '')
         mn = classification.get('mapper_name', '')
         kw = {'oid': event.oid, 'class_name': cn, 'mapper_name': mn}




More information about the Zope-CVS mailing list