Opened 12 years ago

Closed 9 years ago

#17617 closed Cleanup/optimization (fixed)

Middleware Loader swallows useful stacktraces

Reported by: davedash Owned by: nobody
Component: Core (Other) Version: dev
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

This try/except block:

https://github.com/django/django/blob/master/django/core/handlers/base.py#L44

Swallows stacktraces that can help us track down problems. Simply outputting the error raised doesn't really explain what's going on... in our case it was an ImportError caused by a circular import, we had to comment out the try/except to expose it[1].

Not sure what a good way is to fix this, but I thought I'd at the very least mention it.

[1]: https://bugzilla.mozilla.org/show_bug.cgi?id=722497

Change History (2)

comment:1 by Claude Paroz, 12 years ago

Component: UncategorizedCore (Other)
Triage Stage: UnreviewedAccepted
Type: UncategorizedCleanup/optimization
Version: 1.3SVN

Maybe just letting the ImportError uncatched? What is the value added by the encapsulation in a ImproperlyConfigured exception?

comment:2 by Berker Peksag, 9 years ago

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.
Back to Top