[Zope3-Users] Re: meta.zcml from configure.zcml

Philipp von Weitershausen philipp at weitershausen.de
Thu Jul 10 17:01:02 EDT 2008


Jean-François Roche wrote:
>   Design question, is it considered bad practice to include a meta.zcml 
> from a configure.zcml file ?
> 
> e.g Package A depends on package B
> 
> My package A requires some meta defined in package B before loading 
> configure of package B so I do in configure.zcml of package A:
> 
> <configure xmlns="http://namespaces.zope.org/zope"
>            ...
>         >
> 
>    <include·package="B"·file="meta.zcml"·/>
> 
>    <include package="B" />
> 
> </configure>
> 
> Bad ? Ok ?

No, it's ok. If B's meta.zcml were already included earlier on (which 
may have been necessary), then ZCML will simply ignore it the second time.

Normally, we include all metas first, then the configures. But if you 
want to make a package work in isolation (e.g. when the package itself 
describes an application), it makes sense to load meta as well.



More information about the Zope3-users mailing list