diff --git a/django/views/debug.py b/django/views/debug.py index 16cf937d80..6cbbde987b 100644 --- a/django/views/debug.py +++ b/django/views/debug.py @@ -111,6 +111,12 @@ def technical_500_response(request, exc_type, exc_value, tb): }) tb = tb.tb_next + if not frames: + frames = [{ + 'filename': '<unknown>', + 'function': '?', + 'lineno': '?', + }] t = Template(TECHNICAL_500_TEMPLATE) c = Context({ 'exception_type': exc_type.__name__,