diff options
Diffstat (limited to 'coverage/python.py')
-rw-r--r-- | coverage/python.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/coverage/python.py b/coverage/python.py index 8e98bea8..601318c5 100644 --- a/coverage/python.py +++ b/coverage/python.py @@ -51,7 +51,9 @@ def get_python_source(filename): break else: # Couldn't find source. - raise NoSource("No source for code: '%s'." % filename) + exc_msg = "No source for code: '%s'.\n" % (filename,) + exc_msg += "Aborting report output, consider using -i." + raise NoSource(exc_msg) # Replace \f because of http://bugs.python.org/issue19035 source = source.replace(b'\f', b' ') |