Skip to content
Myr

debugger skips two internal frames now

Before adoption: this commit came in with the history the project adopted, so no landing records it.

--HG-- branch : trunk

authored by Armin Ronacher · committed by Armin Ronacher · parent 8e8d071 · Browse files · 1 file+4 added−2 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+4 added−2 removed

  • other:+4 added−2 removed

1 file+4 added−2 removed

modified:jinja2/debug.py+4 added-2 removed
15 unmodified lines
16 """If passed an exc_info it will automatically rewrite the exceptions17 all the way down to the correct line numbers and frames.18 """19 result_tb = prev_tb = None20 initial_tb = tb = exc_info[2]20 initial_tb = tb = exc_info[2].tb_next2122 while tb is not None:23 template = tb.tb_frame.f_globals.get('__jinja_template__')24 if template is not None:
39 unmodified lines
64 if tb_back is not None:65 tb_set_next(tb_back, exc_info[2])66 if tb is not None:67 tb_set_next(exc_info[2].tb_next, tb.tb_next)68 return exc_info6869 # return without this frame70 return exc_info[:2] + (exc_info[2].tb_next,)717273def _init_ugly_crap():74 """This function implements a few ugly things so that we can patch the75 traceback objects. The function returned allows resetting `tb_next` on76 any python traceback object.
63 unmodified lines