Linenumbers: inspect.getinnerframes vs. traceback.format_exception

Thomas Guettler guettli at thomas-guettler.de
Mon Oct 11 13:55:13 CEST 2004


Am Mon, 11 Oct 2004 13:29:30 +0200 schrieb Thomas Guettler:

> Hi,
> 
> the line numbers of inspect.getinnerframes are
> different from traceback.format_exception.

Found the fix in the CVS:

Revision 1.47.8.1  - (view) (download) (as text) (annotate) - [select for
diffs] Sat Jun 5 14:14:48 2004 UTC (4 months ago) by akuchling Branch:
release23-maint
Changes since 1.47: +3 -1 lines
Diff to previous 1.47

[Bug #954364] inspect.getframeinfo() sometimes produces incorrect traceback line #s;
 fix is to look at tb.tb_lineno, not tb.frame.f_lineno.  Patch from Robin
 Becker and me.

 Thomas




More information about the Python-list mailing list