#18807: Inconsistency in the default views
------------------------------------------------+------------------------
               Reporter:  aaugustin             |          Owner:  nobody
                   Type:  Cleanup/optimization  |         Status:  new
              Component:  Core (Other)          |        Version:  master
               Severity:  Normal                |       Keywords:
           Triage Stage:  Unreviewed            |      Has patch:  0
    Needs documentation:  0                     |    Needs tests:  0
Patch needs improvement:  0                     |  Easy pickings:  0
                  UI/UX:  0                     |
------------------------------------------------+------------------------
 `django.views.defaults.permission_denied` will respond ``<h1>403
 Forbidden</h1>`` if no ``403.html`` template is found. This behavior was
 introduced to provide
 [https://code.djangoproject.com/ticket/5515#comment:16 backwards
 compatibility]. Generally speaking, it is a reasonable fallback.

 I believe that `page_not_found` and `server_error` could benefit from a
 similar fallback.

 That would prevent 404s from turning into 500s when there's no 404.html
 template. I know we want to encourage custom error pages, but in case a
 developer skips them, a bare ``<h1>404 Not Found</h1>`` is less damaging
 than a 500 with a backtrace or no content at all.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/18807>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to