diff options
author | Tim Hatch <tim@timhatch.com> | 2013-05-09 17:47:43 -0700 |
---|---|---|
committer | Tim Hatch <tim@timhatch.com> | 2013-05-09 17:47:43 -0700 |
commit | 378a7f103bba1eb23bb14bc320ae35abbc217db9 (patch) | |
tree | 3ed15543d95b87cbea09b620521bd99edcf8bb72 /pygments/lexers/agile.py | |
parent | e6ee6af9da9b8f5d38db70222bc3eca3f8a07110 (diff) | |
download | pygments-378a7f103bba1eb23bb14bc320ae35abbc217db9.tar.gz |
Fix Python 3 traceback parsing to handle non-file lines.
Fixes #859
Diffstat (limited to 'pygments/lexers/agile.py')
-rw-r--r-- | pygments/lexers/agile.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/pygments/lexers/agile.py b/pygments/lexers/agile.py index 078f0181..31df602b 100644 --- a/pygments/lexers/agile.py +++ b/pygments/lexers/agile.py @@ -428,10 +428,13 @@ class Python3TracebackLexer(RegexLexer): r'exception occurred:\n\n', Generic.Traceback), (r'^The above exception was the direct cause of the ' r'following exception:\n\n', Generic.Traceback), + (r'^(?= File "[^"]+", line \d+)', Generic.Traceback, 'intb'), ], 'intb': [ (r'^( File )("[^"]+")(, line )(\d+)(, in )(.+)(\n)', bygroups(Text, Name.Builtin, Text, Number, Text, Name, Text)), + (r'^( File )("[^"]+")(, line )(\d+)(\n)', + bygroups(Text, Name.Builtin, Text, Number, Text)), (r'^( )(.+)(\n)', bygroups(Text, using(Python3Lexer), Text)), (r'^([ \t]*)(\.\.\.)(\n)', |