[Distutils] namespace packages broken in ubuntu with zc.buildout 1.5?

Jim Fulton jim at zope.com
Thu Apr 12 15:38:43 CEST 2012


See the posts from Felix Schwarz here a few days ago.  It looks like
he ran into and
debugged the same issue.  I haven't had a chance to wade into it. (I can't
say I'm looking forward to it.)

I'll try to get up to speed on this this weekend.

Jim

On Thu, Apr 12, 2012 at 6:16 AM, Wichert Akkerman <wichert at wiggy.net> wrote:
> I am running into something very odd on an Ubuntu 11.10 system: it looks
> like namespace packages are entirely broken there. Here is a pdb session to
> demonstrate:
>
> (Pdb) import repoze
> (Pdb) repoze
> <module 'repoze' from
> '/home/wichert/lib/buildout/eggs/repoze.formapi-0.4.2-py2.7.egg/repoze/__init__.pyc'>
> (Pdb) repoze.__path__
> ['/home/wichert/lib/buildout/eggs/repoze.sphinx.autointerface-0.6.2-py2.7.egg/repoze',
> '/home/wichert/lib/buildout/eggs/repoze.formapi-0.4.2-py2.7.egg/repoze']
>
> So at this point I can import the repoze namespace packages, which is
> defined by both repoze.sphinx.autointerface and repoze.formapi. Now I try to
> import repoze.sphinx.autointerface:
>
> (Pdb) import repoze.sphinx.autointerface
> *** ImportError: No module named autointerface
>
> That is unexpected since we saw the repoze.sphinx.autointerface egg was
> found earlier. So lets look at repoze.sphinx:
>
> (Pdb) repoze.sphinx
> <module 'repoze.sphinx' from
> '/usr/lib/pymodules/python2.7/sphinx/__init__.pyc'>
>
> I did not see that coming at all: how can a system sphinx package that is
> not inside the repoze namespace suddenly appear there? This is especially
> odd since buildout hooked me up with a sphinx package in the buildout
> itself:
>
> (Pdb) import sphinx
> <module 'sphinx' from
> '/home/wichert/lib/buildout/eggs/Sphinx-1.0.1-py2.7.egg/sphinx/__init__.pyc'>
>
> I am not sure who is responsible for this behaviour or how to debug this.
> Does anyone have any useful hints?
>
> Wichert.
>
> _______________________________________________
> Distutils-SIG maillist  -  Distutils-SIG at python.org
> http://mail.python.org/mailman/listinfo/distutils-sig



-- 
Jim Fulton
http://www.linkedin.com/in/jimfulton
Jerky is better than bacon! http://www.dublinstore.com/


More information about the Distutils-SIG mailing list