[Zope-dev] Re: How to publish Zope2 products on PyPI

Philipp von Weitershausen philipp at weitershausen.de
Sat Sep 22 13:19:38 EDT 2007

Martin Aspeli wrote:
> Andreas Jung wrote:
>> --On 22. September 2007 12:40:04 +0100 Martin Aspeli 
>> <optilude at gmx.net> wrote:
>>> Andreas Jung wrote:
>>>> I think there are currently several approaches doing 
>>>> products-as-eggs in
>>>> the Zope 2 world - I also lost track a bit and have no idea how to 
>>>> do it
>>>> the right way[tm].
>>> To my knowledge, there are only two, complementary approaches:
>>>   1. Keep the Products.* namespace
>>>     - distribute your egg with a namespace package 'Products'
>>>     - only works (reliably) on zope trunk/2.11+
>>>     - ZCML processing and initialize() is implicit/automated
>>>   2. Use a regular python package (whether with a namespace or not)
>>>     - distribute your egg with any namespace (or no namespace)
>>>     - most of the plone.app.* packages are products
>>>     - works on Zope 2.10.4+
>>>     - ZCML is only processed if the package is explicitly included from
>>> site.zcml (or a ZCML slug, or another package/product that is being
>>> processed)
>>>     - The package only becomes a product if the <five:registerPackage />
>>> ZCML directive is in use
>> Tnx for clarification. Another question: what's the point not using 
>> entry points since service discovery is one of the reasons for using 
>> entry points.
>> Ok, with globally installed eggs this will lead to a 
>> disaster...however for isolated installations via buildout or 
>> something similar using entry points might be useful.
> I agree that this seems a natural fit. I think Philipp experimented with 
> it, but when it turned out that Products.* scanning worked even in eggs 
> that used Products.* as a namespace package, he decided there wasn't 
> much point in continuing.
> So: Entry points could potentially do what the <five:registerPackage /> 
> directive does to register products. However, we already have that (and 
> the magic Products.* scanning) so there may not be that much point.


http://worldcookery.com -- Professional Zope documentation and training

More information about the Zope-Dev mailing list