Index: views/debug.py =================================================================== --- views/debug.py (Revision 5754) +++ views/debug.py (Arbeitskopie) @@ -103,9 +103,14 @@ module_name = tb.tb_frame.f_globals.get('__name__') pre_context_lineno, pre_context, context_line, post_context = _get_lines_from_file(filename, lineno, 7, loader, module_name) if pre_context_lineno is not None: + mycode=not re.search( + r'site-packages/|lib.?.?/python|' + r'django/(contrib|core|db|dispatch|(new|old)?forms|http|middleware|shortcuts|template(tags)?|test|utils|views)/', + filename) # Display my files bigger and python/django files smaller. frames.append({ 'tb': tb, 'filename': filename, + 'mycode': mycode, 'function': function, 'lineno': lineno + 1, 'vars': tb.tb_frame.f_locals.items(), @@ -401,7 +406,8 @@
{{ frame.filename|escape }}
in {{ frame.function|escape }}
+ {{ frame.filename|escape }}
in
+ {{ frame.function|escape }}
{% if frame.context_line %}