Installing certain Python Packages fails
Florian Diesch
diesch at spamfence.net
Thu Jun 29 20:54:08 UTC 2006
"David A. Cobb" <superbiskit at cox.net> wrote:
> Running Breezy, kernel 2.6.12.
> Every attempt to install certain Python packages ends badly with the
> following DPKG output:
> Ubuntu Help and User Discussions <ubuntu-users at lists.ubuntu.com>Ubuntu
> Help and User Discussions <ubuntu-users at lists.ubuntu.com>Ubuntu Help and
> User Discussions
> <ubuntu-users at lists.ubuntu.com>/dev/ide/host0/bus0/target1/lun0/part1 on
> /usr type xfs (rw)
> Setting up python2.4-sqlobject (0.6-1ubuntu2) ...
> Compiling
> /usr/lib/python2.4/site-packages/py/test/testing/data/syntax_error.py ...
> File
> "/usr/lib/python2.4/site-packages/py/test/testing/data/syntax_error.py",
> line 3
> this is really not python
> ^
> SyntaxError: invalid syntax
After installing new python packages the package manager tries to
compile all python files in /usr/lib/python2.4/site-packages (see
/var/lib/dpkg/info/python2.4-sqlobject.postinst and
/usr/lib/python2.4/compileall.py).
It seems some package is having some test file there.
dpkg -S /usr/lib/python2.4/site-packages/py/test/testing/data/syntax_error.py
will tell you which package it is.
You have the following options (none of which is nice):
* remove the bad package
* remove or fix syntax_error.py
* modify /usr/lib/python2.4/compileall.py so it doesn't try to compile
syntax-error.py
I any case please file a bug report against the bad package.
Maybe compileall.py should have a config file to exclude dirs from
automatic compilation.
Florian
--
<http://www.florian-diesch.de/>
More information about the ubuntu-users
mailing list