Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fixed #8055: Replaced use of traceback.format_exc (new in Python 2.4)…

… with something that works as far back as 2.3.

Thanks to Ramiro for diagnosis and patch.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@9770 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 81dfd1f5f037019a227a767877b2124311cff738 1 parent 3c87c22
@kmtracey kmtracey authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 django/core/management/commands/loaddata.py
View
4 django/core/management/commands/loaddata.py
@@ -161,12 +161,12 @@ def read(self):
transaction.rollback()
transaction.leave_transaction_management()
if show_traceback:
- import traceback
traceback.print_exc()
else:
sys.stderr.write(
self.style.ERROR("Problem installing fixture '%s': %s\n" %
- (full_path, traceback.format_exc())))
+ (full_path, ''.join(traceback.format_exception(sys.exc_type,
+ sys.exc_value, sys.exc_traceback)))))
return
fixture.close()
Please sign in to comment.
Something went wrong with that request. Please try again.