problem with tabnanny

Skip Montanaro skip at pobox.com
Wed Sep 10 12:52:36 EDT 2003


    Pier> #---------8<---- test.py -------------
        
    Pier> if 1:
    Pier> print "error" 

    Pier> #---------8<------ end test.py -------

    Pier> $ python /usr/lib/python2.2/tabnanny.py -v test.py
    Pier> '/home/pier/test.py': Clean bill of health.

    Pier> for tabnanny it's correct!?

Tabnanny doesn't try to find indentation syntax errors in your code.  It
identifies indentation which mixes spaces and tabs in such a way that the
file might not execute properly because of differing interpretations about
how a TAB indents.  In your case there's no ambiguity because there is no
leading whitespace at all.

Skip





More information about the Python-list mailing list