[ZPT] zope3-dev proposal on changing implicitly calling

Dieter Maurer dieter at handshake.de
Fri Jun 20 21:51:30 EDT 2003


Steve Alexander wrote at 2003-6-20 14:07 +0300:
 > I recently made a proposal on the Zope 3 mailing list that may be of 
 > interest to this list. (I am not subscribed to this list.)
 > 
 >    http://mail.zope.org/pipermail/zope3-dev/2003-June/007372.html
 > 
 > The rationale is in the email above, but I'll copy the proposal below.
 > 
 > Proposal:
 > 
 >     I propose the following:
 > 
 >     1: Remove from Zope 3 the TALES behaviour of calling the result of a
 >        path expression if it has a __call__ attribute.
 > 
 >     2: Deprecating the 'nocall' magic word, as it will no longer be
 >        needed.
 > 
 >     3: Making the zope 3 default traversal machinery call an object on
 >        traversal if and only if the following conditions hold:
 > 
 >        a: the object provides no interfaces

What's the motivation for this?
Why should an object with interface not be (automatically) callable?

 > 
 >        b: the object has a __call__ attribute
 > 
 >        c: on inspection, it appears that the __call__ attribute can be
 >           called with no arguments


Dieter



More information about the ZPT mailing list