diff options
| author | Aymeric Augustin | 2013-10-15 09:46:13 +0200 | 
|---|---|---|
| committer | Aymeric Augustin | 2013-10-15 09:46:13 +0200 | 
| commit | 0bd0abda661af29750bbd3263ab5f93a24b47511 (patch) | |
| tree | 2e8091af987a120ef4f86de6de593bc0d3f6aa3e /debug_toolbar | |
| parent | 9366b7adfa932c1ecafac820a70c3c38584c876f (diff) | |
| download | django-debug-toolbar-0bd0abda661af29750bbd3263ab5f93a24b47511.tar.bz2 | |
Catch exceptions liberally when looking for sources.
Fix #279.
Diffstat (limited to 'debug_toolbar')
| -rw-r--r-- | debug_toolbar/utils/__init__.py | 2 | 
1 files changed, 1 insertions, 1 deletions
| diff --git a/debug_toolbar/utils/__init__.py b/debug_toolbar/utils/__init__.py index 2d2ff10..b8bb4a1 100644 --- a/debug_toolbar/utils/__init__.py +++ b/debug_toolbar/utils/__init__.py @@ -146,7 +146,7 @@ def getframeinfo(frame, context=1):          start = lineno - 1 - context // 2          try:              lines, lnum = inspect.findsource(frame) -        except (IOError, IndexError): +        except Exception:   # findsource raises platform-dependant exceptions              lines = index = None          else:              start = max(start, 1) | 
