SyntaxError tracebacks in 2.2
Has anyone else noticed that SyntaxError tracebacks no longer include the name of the file where the error occurs? Instead, they just say "<file>". Eg. $ python2.1 foo.py File "foo.py", line 1 foo = ^ SyntaxError: invalid syntax $ python2.2 foo.py File "<string>", line 1 foo = ^ SyntaxError: invalid syntax This is annoying enough that I just filed SF bug #516712: http://sourceforge.net/tracker/index.php?func=detail&aid=516712&group_id=5470&atid=105470 Greg -- Greg Ward - Linux nerd gward@python.net http://starship.python.net/~gward/ There are no stupid questions -- only stupid people.
Greg Ward wrote:
Has anyone else noticed that SyntaxError tracebacks no longer include the name of the file where the error occurs? Instead, they just say "<file>". Eg.
$ python2.1 foo.py File "foo.py", line 1 foo = ^ SyntaxError: invalid syntax $ python2.2 foo.py File "<string>", line 1 foo = ^ SyntaxError: invalid syntax
This is annoying enough that I just filed SF bug #516712: http://sourceforge.net/tracker/index.php?func=detail&aid=516712&group_id=5470&atid=105470
I believe Martin fixed this. With the latest from CVS: [neal@epoch src]$ ./python foo.py File "foo.py", line 1 foo = ^ SyntaxError: invalid syntax Neal
participants (3)
-
Greg Ward -
martin@v.loewis.de -
Neal Norwitz