سؤال

comments work fine when debug is on but when I turn it off I get "an error occurred" message and it fails to redirect me back to the original page, instead showing the error message at url "www.MYSITE/comments". I'm using django threaded comments on Mezzanine if that helps. I'd just like a way to see the error message at least. Best,

jake

هل كانت مفيدة؟

المحلول

Have you tried using Django Middleware, more precisely the process_exception part? You can write your own middleware class to log the exception or display it in the result page.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top