15 Dec
2005
15 Dec
'05
9:01 p.m.
Andreas Jung wrote:
--On 14. Dezember 2005 12:54:56 -0700 Nikko Wolf <nikko-wolf@earthlink.net> wrote:
So you could try this instead:
for item in itemList: try: context.afolder.manage_delObjects([item]) except: continue
Wahhhh... DON'T DO THAT. You should *never* use bare try..excepts within Zope applications. This can lead to strange and unpredictable behavior.
Can you elaborate on what "strange and unpredictable behavior" you mean? I'm curious in general, but especially w.r.t. the code above? BTW, a simple grep of sources in Zope (2.7.6-final) turns up 600+ places where a bare except is used, and my Zope instance (which uses Plone) contains over 350 more. Cheers, Nikko