diff options
| author | konarkmodi <modi.konark@gmail.com> | 2013-03-19 10:34:59 +0530 |
|---|---|---|
| committer | Carl Meyer <carl@oddbird.net> | 2013-03-19 15:42:39 -0700 |
| commit | bc4111ba68e5eede1f68882a16d68441a845e30b (patch) | |
| tree | 0b7689470b8ff28cdaee5fbe5053b81c720fd497 /django/utils/http.py | |
| parent | 1fe90b281baa1601e4582fd9454b92740e527d89 (diff) | |
Fixed #18003 -- Preserved tracebacks when re-raising errors.
Thanks jrothenbuhler for draft patch, Konark Modi for updates.
Diffstat (limited to 'django/utils/http.py')
| -rw-r--r-- | django/utils/http.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/django/utils/http.py b/django/utils/http.py index 0ab5198804..73b6396286 100644 --- a/django/utils/http.py +++ b/django/utils/http.py @@ -144,7 +144,7 @@ def parse_http_date(date): result = datetime.datetime(year, month, day, hour, min, sec) return calendar.timegm(result.utctimetuple()) except Exception: - raise ValueError("%r is not a valid date" % date) + six.reraise(ValueError, ValueError("%r is not a valid date" % date), sys.exc_info()[2]) def parse_http_date_safe(date): """ |
