1
0
mirror of https://github.com/django/django.git synced 2025-10-31 09:41:08 +00:00

Fixed #10841 -- Switched response served when DEBUG=True and request.is_ajax() returns True (indicating request has been generated by a JS library) to a plain text version for easier debugging.

Contents of this response are similar to its HTML counterpart modulo frame variables values in the Python traceback section.

Thanks to Riz for the report, to SmileyChris for the patch and to Julien for reviewing.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16921 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Ramiro Morales
2011-10-02 02:53:58 +00:00
parent 28ee7a9df3
commit 0d9b6a5bc4
3 changed files with 246 additions and 31 deletions

View File

@@ -339,6 +339,17 @@ Django 1.4 also includes several smaller improvements worth noting:
be able to retrieve a translation string without displaying it but setting
a template context variable instead.
* A new plain text version of the HTTP 500 status code internal error page
served when :setting:`DEBUG` is ``True`` is now sent to the client when
Django detects that the request has originated in JavaScript code
(:meth:`~django.http.HttpRequest.is_ajax` is used for this).
Similarly to its HTML counterpart, it contains a collection of different
pieces of information about the state of the web application.
This should make it easier to read when debugging interaction with
client-side Javascript code.
.. _backwards-incompatible-changes-1.4:
Backwards incompatible changes in 1.4