From 0205e04ce7a554a7b9b27b412288cc6a0e75e48f Mon Sep 17 00:00:00 2001 From: Tim Graham Date: Wed, 1 Feb 2017 19:38:25 -0500 Subject: [PATCH] Removed ExceptionReporter support for string exceptions. Reverted refs #6423 since raising string exceptions is prohibited since Python 2.5. --- django/views/debug.py | 5 ----- 1 file changed, 5 deletions(-) diff --git a/django/views/debug.py b/django/views/debug.py index 4fe3f35a2e..945e77440e 100644 --- a/django/views/debug.py +++ b/django/views/debug.py @@ -246,11 +246,6 @@ class ExceptionReporter: self.template_does_not_exist = False self.postmortem = None - # Handle deprecated string exceptions - if isinstance(self.exc_type, str): - self.exc_value = Exception('Deprecated String Exception: %r' % self.exc_type) - self.exc_type = type(self.exc_value) - def get_traceback_data(self): """Return a dictionary containing traceback information.""" if self.exc_type and issubclass(self.exc_type, TemplateDoesNotExist):