On Fri, 2002-10-04 at 16:37, Leonardo Rochael Almeida wrote:
> I'm testing a fix for the TALES case along the lines of what Casey
> sugested and will report back with results.

And here it is. TALES actually had a slot for my change, go figure :-)

as for PluginIndex/common/UnIndex.py, I'd like to propose the following
rule, before I attempt a fix:

No bare 'except:' shall silently ingore it's exception and proceed.
Outside of ZPublisher, any bare 'except:' MUST raise either the original
exception or another one. Inside of ZPublisher it's too dark to read.

What do you think?

Cheers, Leo

PS: in PageTemplates/TALES.py there's another bare 'except:' in the
Iterator class, I suggest it be changed to include a self._nocatch
mechanism just like the Context class in that same file. What do you

Ideas don't stay in some minds very long because they don't like
solitary confinement.

--- lib/python/Products/PageTemplates/Expressions.py-orig       2002-10-04 
17:26:31.000000000 +0000
+++ lib/python/Products/PageTemplates/Expressions.py    2002-10-04 17:26:38.000000000 
@@ -24,6 +24,7 @@
      TALESError, Undefined, Default, _parse_expr
 from string import strip, split, join, replace, lstrip
 from Acquisition import aq_base, aq_inner, aq_parent
+from ZODB.POSException import ConflictError
 _engine = None
@@ -33,7 +34,7 @@
         from PathIterator import Iterator
         _engine = Engine(Iterator)
-        _engine._nocatch = (TALESError, 'Redirect')
+        _engine._nocatch = (TALESError, 'Redirect', ConflictError)
     return _engine
 def installHandlers(engine):

Reply via email to