Commit 27067290 authored by Florent Guillaume's avatar Florent Guillaume

ConflictError was swallowed in ObjectManager by manage_beforeDelete and

_delObject. This could break code expecting to do cleanups before
deletion.
parent c3cabf52
...@@ -29,6 +29,11 @@ Zope Changes ...@@ -29,6 +29,11 @@ Zope Changes
(such as storages, databases, or logging handlers) to be used. (such as storages, databases, or logging handlers) to be used.
Bugs fixed Bugs fixed
- ConflictError was swallowed in ObjectManager by
manage_beforeDelete and _delObject. This could break code
expecting to do cleanups before deletion.
- Python 2.3 BooleanType wasn't handled properly by ZTUtils - Python 2.3 BooleanType wasn't handled properly by ZTUtils
marshalling and ZPublisher's converters. marshalling and ZPublisher's converters.
......
...@@ -12,9 +12,9 @@ ...@@ -12,9 +12,9 @@
############################################################################## ##############################################################################
__doc__="""Object Manager __doc__="""Object Manager
$Id: ObjectManager.py,v 1.163 2003/02/11 21:06:28 fdrake Exp $""" $Id: ObjectManager.py,v 1.164 2003/11/02 18:02:36 efge Exp $"""
__version__='$Revision: 1.163 $'[11:-2] __version__='$Revision: 1.164 $'[11:-2]
import App.Management, Acquisition, Globals, CopySupport, Products import App.Management, Acquisition, Globals, CopySupport, Products
import os, App.FactoryDispatcher, re, Products import os, App.FactoryDispatcher, re, Products
...@@ -28,6 +28,7 @@ from webdav.Collection import Collection ...@@ -28,6 +28,7 @@ from webdav.Collection import Collection
from Acquisition import aq_base from Acquisition import aq_base
from AccessControl.SecurityInfo import ClassSecurityInfo from AccessControl.SecurityInfo import ClassSecurityInfo
from webdav.Lockable import ResourceLockedError from webdav.Lockable import ResourceLockedError
from ZODB.POSException import ConflictError
from urllib import quote from urllib import quote
from cStringIO import StringIO from cStringIO import StringIO
import marshal import marshal
...@@ -300,6 +301,8 @@ class ObjectManager( ...@@ -300,6 +301,8 @@ class ObjectManager(
object.manage_beforeDelete(item, container) object.manage_beforeDelete(item, container)
except BeforeDeleteException, ob: except BeforeDeleteException, ob:
raise raise
except ConflictError:
raise
except: except:
LOG('Zope',ERROR,'manage_beforeDelete() threw', LOG('Zope',ERROR,'manage_beforeDelete() threw',
error=sys.exc_info()) error=sys.exc_info())
...@@ -312,6 +315,8 @@ class ObjectManager( ...@@ -312,6 +315,8 @@ class ObjectManager(
object.manage_beforeDelete(object, self) object.manage_beforeDelete(object, self)
except BeforeDeleteException, ob: except BeforeDeleteException, ob:
raise raise
except ConflictError:
raise
except: except:
LOG('Zope',ERROR,'manage_beforeDelete() threw', LOG('Zope',ERROR,'manage_beforeDelete() threw',
error=sys.exc_info()) error=sys.exc_info())
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment