[Grok-dev] Re: Salt & z3c.autoinclude

Martin Aspeli optilude at gmx.net
Fri Mar 21 15:35:07 EDT 2008

Martijn Faassen wrote:
> Martin Aspeli wrote:
> [snip]
>> What I don't quite understand is how the ZCML <autoinclude package="." 
>> /> understands that it should go and get the things where target is 
>> 'plone' and not get all packages. I think it is easier conceptually to say:
>>   <autoinclude platform="plone" />
> autoinclude is not the directive you should be looking at. That's to 
> automatically include all ZCML for dependencies mentioned in a setup.py.

Aha! :)

> You should look at <includePlugins>. It *should* get the 'package' 
> argument, as it will include all plugins registered for that package. No 
> need to come up with other namespaced identifiers for packages that have 
> plugins when their package name is already a namespaced identifier. You 
> can expect people who write setup.py files to know about package names, 
> and also be aware of Plone's package name, after all.

So you mean the entry point is:

Products.CMFPlone = my.package


That makes sense.

>> Also, how do we handle meta.zcml? Do we need an autoinclude directive in 
>> a package's own meta.zcml or can we get away with an ordering where all 
>> meta.zcml files are done first (in which case we have to rely on the 
>> name) and all others are done last.
> includePlugins should work like autoinclude here, in that it loads any 
> meta.zcml (if available) of plugins first, and then proceeds loading up 
> the configure.zcml files.



More information about the Grok-dev mailing list