[Distutils] Problem importing pylirc egg

Philippe Normand philippe at fluendo.com
Mon Apr 24 21:30:04 CEST 2006

Le 24/4/2006, "Phillip J. Eby" <pje at telecommunity.com> a écrit:
>Try "import pylircmodule" - it looks like this may be a bug in building
>compressed eggs; if an extension module in a zipfile ends with 'module',
>the bdist_egg command probably isn't stripping the word 'module' from the
>loader name.
>If that works, try reinstalling the egg using -Z (or --always-unzip), and
>see if you can just use "import pylirc".  In that case, it is indeed a bug
>in bdist_egg.

Gotcha ! :)

I tried importing pylircmodule:

>>> import pylircmodule
Traceback (most recent call last):
  File "<stdin>", line 1, in ?
  File "build/bdist.linux-i686/egg/pylircmodule.py", line 7, in ?
  File "build/bdist.linux-i686/egg/pylircmodule.py", line 6, in
ImportError: dynamic module does not define init function

Re-installed the Egg as you advised, renammed pylircmodule.py to

>>> import pylirc
>>> pylirc.__file__

So it seems to be a bug ;)

More information about the Distutils-SIG mailing list