Possible Duplicate:
Log all errors to console or file on Django site
Is it possible to make the Django development server print all the exceptions to stdout
as well as returning them in HTTP responses? I don't want to debug them, I just want to see stack traces.
The reason I want to do this, is because when I make AJAX calls, and there are errors, I have to use Firebug to see where the error occurred (as they are returned in HTML responses). It would just be quicker if I could see them in the runserver
's console.
Right now, it only prints HTTP response codes.
Edit: Alright, I've realized that this question is a duplicate. I've solved the issue by adding a few lines of code to handle_uncaught_exception
in base.py
:
import pprint;
if settings.DEBUG:
pprint.pprint(exc_info);