[py-svn] r58888 - py/trunk/py/code
fijal at codespeak.net
fijal at codespeak.net
Fri Oct 10 11:59:31 CEST 2008
Author: fijal
Date: Fri Oct 10 11:59:31 2008
New Revision: 58888
Modified:
py/trunk/py/code/traceback2.py
Log:
Catch all possible find_source errors
Modified: py/trunk/py/code/traceback2.py
==============================================================================
--- py/trunk/py/code/traceback2.py (original)
+++ py/trunk/py/code/traceback2.py Fri Oct 10 11:59:31 2008
@@ -58,7 +58,9 @@
if source is None:
try:
sourcelines, lineno = py.std.inspect.findsource(self.frame.code.raw)
- except IOError:
+ except (KeyboardInterrupt, SystemExit):
+ raise
+ except:
return None
source = py.code.Source()
source.lines = map(str.rstrip, sourcelines)
More information about the pytest-commit
mailing list