[prev in list] [next in list] [prev in thread] [next in thread]
List: zodb-checkins
Subject: [Zodb-checkins] CVS: Zope/lib/python/ZODB - Transaction.py:1.49.4.3
From: michael dunstan <michael () elyt ! com>
Date: 2004-05-22 22:39:12
Message-ID: 200405222239.i4MMdCVl015760 () cvs ! zope ! org
[Download RAW message or body]
Update of /cvs-repository/Zope/lib/python/ZODB
In directory cvs.zope.org:/tmp/cvs-serv15301/lib/python/ZODB
Modified Files:
Tag: Zope-2_7-branch
Transaction.py
Log Message:
- Collector #852: Bug in the error reporting of some failure
cases in transactions meant that the cause of the failure was
not logged.
=== Zope/lib/python/ZODB/Transaction.py 1.49.4.2 => 1.49.4.3 ===
--- Zope/lib/python/ZODB/Transaction.py:1.49.4.2 Thu Jan 22 23:51:13 2004
+++ Zope/lib/python/ZODB/Transaction.py Sat May 22 18:38:28 2004
@@ -137,8 +137,11 @@
if t is None:
t, v, tb = sys.exc_info()
else:
- self.log("Failed to abort object %s" %
- oid_repr(o._p_oid), error=sys.exc_info())
+ if getattr(o,'_p_oid',None):
+ msg = "Failed to abort object %s" % repr(o._p_oid)
+ else:
+ msg = "Failed to abort object"
+ self.log(msg, error=sys.exc_info())
# tpc_begin() was never called, so tpc_abort() should not be
# called.
@@ -390,8 +393,11 @@
j.abort(o, self)
except:
# nothing to do but log the error
- self.log("Failed to abort object %s" % oid_repr(o._p_oid),
- error=sys.exc_info())
+ if getattr(o,'_p_oid',None):
+ msg = "Failed to abort object %s" % repr(o._p_oid)
+ else:
+ msg = "Failed to abort object"
+ self.log(msg, error=sys.exc_info())
# Abort the two-phase commit. It's only necessary to abort the
# commit for jars that began it, but it is harmless to abort it
_______________________________________________
Zodb-checkins mailing list
Zodb-checkins@zope.org
http://mail.zope.org/mailman/listinfo/zodb-checkins
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic