[Zope3-dev] Re: One namespace for ZCML

Tres Seaver tseaver at palladion.com
Tue Feb 14 06:44:35 EST 2006

Hash: SHA1

Philipp von Weitershausen wrote:


> Just note that I'm explicitly not addressing automation as a use case for
> custom ZCML directives. I believe automation is best done in Python. If you're
> trying to invent a new ZCML directive that does something else to an
> adapter/view/utility before registering it (e.g. putting an interface on it,
> adding attributes, wrapping it in a factory etc.), then that should be done in
> Python. zope.formlib is a good example of how browser:page is enough for
> registering a form as it isn't ZCML's concern *what* kind of page we're
> registering. All that is in Python.

I'll aggree to an extent:  where this pactice breaks down is when the
"argumentes" to the automation need to be supplied as configuration.  At
that point, a wrapper argument which allows the user to specify those
values without writing / modifying PYthon can be a win.  In the case of
Shane's "webroot" proposal, for instance, the filesystem path to the
root would be best specified as an attribute to a custom directive, even
if the directive did nothing more than configure a single global utility.


- --
Tres Seaver          +1 202-558-7113          tseaver at palladion.com
Palladion Software   "Excellence by Design"    http://palladion.com
Version: GnuPG v1.4.1 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org


More information about the Zope3-dev mailing list