diff options
author | Ned Batchelder <ned@nedbatchelder.com> | 2011-04-08 22:21:18 -0400 |
---|---|---|
committer | Ned Batchelder <ned@nedbatchelder.com> | 2011-04-08 22:21:18 -0400 |
commit | 50f2239ca3c565b28c25b51371c42b569fa05a8c (patch) | |
tree | c0bd675abd1570e7f9517f6271fc666d620d00f6 /coverage/misc.py | |
parent | 4d395ed6ac593efe933909f88dab05def0edcd2e (diff) | |
download | python-coveragepy-git-50f2239ca3c565b28c25b51371c42b569fa05a8c.tar.gz |
Deal more gracefully with unexpectedly-not-python source during reporting.
Diffstat (limited to 'coverage/misc.py')
-rw-r--r-- | coverage/misc.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/coverage/misc.py b/coverage/misc.py index 6cc42c74..4f3748fe 100644 --- a/coverage/misc.py +++ b/coverage/misc.py @@ -113,7 +113,11 @@ class CoverageException(Exception): pass class NoSource(CoverageException): - """Used to indicate we couldn't find the source for a module.""" + """We couldn't find the source for a module.""" + pass + +class NotPython(CoverageException): + """A source file turned out not to be parsable Python.""" pass class ExceptionDuringRun(CoverageException): |