Re: [Distutils] namespace_packages
At 12:44 PM 01/20/2006 -0500, Charlie Moad wrote:
Here are the eggs if you want to unzip and look at them. I installed both unzipped.
http://euclid.uits.iupui.edu/~cmoad/mpleggs/matplotlib-0.86.2cvs-py2.4-linux... http://euclid.uits.iupui.edu/~cmoad/mpleggs/basemap-0.8-py2.4-linux-i686.egg
There are two issues that I saw. First, the matplotlib egg above does not declare a namespace in its matplotlib/__init__.py. Second, the basemap egg does not contain a matplotlib/__init__.py at all. Please note that you *must* include an __init__.py file for every namespace package and parent package thereof, in *every* egg that's part of the namespace package, and that these __init__.py files must all contain a namespace declaration. Missing even one can cause problems. For example, the basemap egg is simply not importable, because as far as Python is concerned it does not contain a matplotlib package (due to the missing __init__.py).
Thanks for all your help. It is finally working. Another commit pulled out my declare_nmsp in mpl/__init__.py and I needed to specify the matplotlib module in basemap's setup.py for the __init__.py to get included in the install. Thanks again, - Charlie On 1/20/06, Phillip J. Eby <pje@telecommunity.com> wrote:
At 12:44 PM 01/20/2006 -0500, Charlie Moad wrote:
Here are the eggs if you want to unzip and look at them. I installed both unzipped.
http://euclid.uits.iupui.edu/~cmoad/mpleggs/matplotlib-0.86.2cvs-py2.4-linux... http://euclid.uits.iupui.edu/~cmoad/mpleggs/basemap-0.8-py2.4-linux-i686.egg
There are two issues that I saw. First, the matplotlib egg above does not declare a namespace in its matplotlib/__init__.py. Second, the basemap egg does not contain a matplotlib/__init__.py at all.
Please note that you *must* include an __init__.py file for every namespace package and parent package thereof, in *every* egg that's part of the namespace package, and that these __init__.py files must all contain a namespace declaration. Missing even one can cause problems. For example, the basemap egg is simply not importable, because as far as Python is concerned it does not contain a matplotlib package (due to the missing __init__.py).
participants (2)
-
Charlie Moad -
Phillip J. Eby