andrew.degtiariov at gmail.com
Mon Feb 8 22:39:42 CET 2010
Those are called namespace packages. Zope and Plone (ab)use them
> extensively. The intended usage is to break up a big, monolithic package
>  in parts that can be distributed independently. To implement a
> namespace package, you need an empty __init__.py file with only these
> lines :
> from pkgutil import extend_path
> __path__ = extend_path(__path__, __name__)
> But think carefully if you really need namespace packages; they solve a
> specific problem, aren't a general purpose technique. See  for a
>  Think of a huge behemoth with a "Z O P E" sign on both sides :)
>  http://docs.python.org/library/pkgutil.html
>  http://weblion.psu.edu/news/are-we-overusing-namespace-packages
Hm.. We are using pkg_resources.declare_namespace(__name__) but I think
pkgutil is much better.
And we are using buildout so the omelette might help me. Link  very
Thank you, Gabrial.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Python-list