[Zope-CMF] Delete trouble

Martin Aspeli optilude at gmx.net
Sat Mar 24 15:21:45 EDT 2007


Hi guys,

At the moment, with the tools-as-utilities branched merged, it's 
sometimes impossible to delete a Plone site. I haven't looked too deeply 
into it, and I don't have a test for it, unfortunately, but it seems 
that when content has been added, we get errors like the one below. It 
seems to me like in this case, a particular utility has been removed 
before something that assumes it's there is deleted.

There is nothing Plone specific about this error, i.e. nowhere in Plone 
that we can make changes to avoid it. We did have a similar problem in 
AT's catalog multiplex despatcher which we solved by checking for 
ComponentLookupErrors.

I think resolving all of these errors through re-ordering of calls and 
the like could be quite tricky. It's something of a cop-out, but it's 
probably easier to insert a lower level catch all for 
ComponentLookupErrors in e.g. CMFCatalogAware's event handlers.

What do people think of this idea? At the moment, it's painful to do 
development on Plone; I have instances in my ZODB like test, test1, 
test2, test3, test4... ;-)

Traceback (innermost last):
   Module ZPublisher.Publish, line 119, in publish
   Module ZPublisher.mapply, line 88, in mapply
   Module ZPublisher.Publish, line 42, in call_object
   Module OFS.ObjectManager, line 524, in manage_delObjects
   Module OFS.ObjectManager, line 379, in _delObject
   Module zope.event, line 23, in notify
   Module zope.component.event, line 26, in dispatch
   Module zope.component._api, line 130, in subscribers
   Module zope.component.registry, line 290, in subscribers
   Module zope.interface.adapter, line 535, in subscribers
   Module zope.component.event, line 33, in objectEventNotify
   Module zope.component._api, line 130, in subscribers
   Module zope.component.registry, line 290, in subscribers
   Module zope.interface.adapter, line 535, in subscribers
   Module OFS.subscribers, line 108, in dispatchObjectWillBeMovedEvent
   Module zope.app.container.contained, line 182, in dispatchToSublocations
   Module zope.component._api, line 130, in subscribers
   Module zope.component.registry, line 290, in subscribers
   Module zope.interface.adapter, line 535, in subscribers
   Module OFS.subscribers, line 108, in dispatchObjectWillBeMovedEvent
   Module zope.app.container.contained, line 182, in dispatchToSublocations
   Module zope.component._api, line 130, in subscribers
   Module zope.component.registry, line 290, in subscribers
   Module zope.interface.adapter, line 535, in subscribers
   Module Products.CMFCore.CMFCatalogAware, line 285, in 
dispatchToOpaqueItems
   Module zope.component._api, line 130, in subscribers
   Module zope.component.registry, line 290, in subscribers
   Module zope.interface.adapter, line 535, in subscribers
   Module Products.CMFCore.CMFCatalogAware, line 306, in 
handleOpaqueItemEvent
   Module Products.CMFUid.UniqueIdAnnotationTool, line 87, in 
manage_beforeDelete
   Module zope.component._api, line 207, in getUtility
ComponentLookupError: (<InterfaceClass 
Products.CMFUid.interfaces.IUniqueIdAnnotationManagement>, '')

Martin



More information about the Zope-CMF mailing list