diff --git a/django/views/debug.py b/django/views/debug.py index 0370204764..d1e9259243 100644 --- a/django/views/debug.py +++ b/django/views/debug.py @@ -254,7 +254,7 @@ def technical_404_response(request, exception): t = Template(TECHNICAL_404_TEMPLATE, name='Technical 404 template') c = Context({ 'root_urlconf': settings.ROOT_URLCONF, - 'request_path': request.path[1:], # Trim leading slash + 'request_path': request.path_info[1:], # Trim leading slash 'urlpatterns': tried, 'reason': smart_str(exception, errors='replace'), 'request': request, @@ -282,7 +282,7 @@ TECHNICAL_500_TEMPLATE = """
-