[csw-maintainers] Problem compiling Python files

Maciej (Matchek) Blizinski maciej at opencsw.org
Fri Sep 25 14:39:09 CEST 2009


On Fri, Sep 25, 2009 at 1:27 PM, Ben Walton <bwalton at opencsw.org> wrote:
> Excerpts from Dagobert Michelsen's message of Fri Sep 25 02:40:46 -0400 2009:
>
> Hi Dago,
>
>> > Compiling /opt/csw/lib/python/site-packages/_xmlplus/parsers/xmlproc/
>> > dtdparser.py ...
>> > Sorry: TabError: ('inconsistent use of tabs and spaces in
>> > indentation', ('/opt/csw/lib/python/site-packages/_xmlplus/parsers/
>> > xmlproc/dtdparser.py', 500, 33, '\t    elif self.now_at("#FIXED"):
>> > \n'))
>
> That file seems to be part of CSWpyxml, which has a REV stamp of
> 2008.03.17, which is well before cswpycompile came about.  I don't see
> a version of it in testing/, either.  It _shouldn't_, as far as I can
> tell, even be compiling its files at install time.
>
> I pulled it onto a machine here and didn't get the errors.
>
> Am I missing something?

I kept on seeing that each time I installed a Python package using
cswpycompile, it could (re)compile all the existing .py files, not
just the ones being installed. Perhaps there were .py files lying
around? Try to put a broken .py file in site-packages and reinstall
the package.

When I do that and install any package which uses cswpycompile, I'm getting:

Compiling /opt/csw/lib/python/site-packages/broken.py ...
Sorry: IndentationError: ('unexpected indent',
('/opt/csw/lib/python/site-packages/broken.py', 3, 2, '\t\t"is"\n'))


Maciej



More information about the maintainers mailing list