Opened 15 years ago

Closed 14 years ago

Last modified 13 years ago

#11990 closed (fixed)

TECHNICAL_404_TEMPLATE doesn't see URLConfs directly on request objects

Reported by: mattbennett Owned by: nobody
Component: Core (Other) Version: dev
Severity: Keywords: 404, urlconf, debug, template
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

The default debug 404 template in django/views/debug.py assumes that the urlconf searched was the root urlconf. Since [4237] the urlconf can be set by middleware, so this is not necessarily the case.

The attached patch puts the module name of the urlconf being used into the template context, and modifies the template accordingly.

Attachments (1)

technical_404_urlconf.patch (1.3 KB ) - added by mattbennett 15 years ago.

Download all attachments as: .zip

Change History (5)

by mattbennett, 15 years ago

Attachment: technical_404_urlconf.patch added

comment:1 by Russell Keith-Magee, 15 years ago

milestone: 1.2
Triage Stage: UnreviewedAccepted

comment:2 by Russell Keith-Magee, 15 years ago

milestone: 1.21.3
Triage Stage: AcceptedReady for checkin

comment:3 by Jannis Leidel, 14 years ago

Resolution: fixed
Status: newclosed

(In [14877]) Fixed #11990 -- Show the correct URLconf in the technical 404 template even if it was overridden, e.g. in a middleware. Thanks, mattbennett.

comment:4 by Jacob, 13 years ago

milestone: 1.3

Milestone 1.3 deleted

Note: See TracTickets for help on using tickets.
Back to Top