diff options
author | Ned Batchelder <ned@nedbatchelder.com> | 2018-09-09 07:42:14 -0400 |
---|---|---|
committer | Ned Batchelder <ned@nedbatchelder.com> | 2018-09-09 07:42:14 -0400 |
commit | d8da2b9a6cf5c127c9ba9393c716d9dc4dd50cbe (patch) | |
tree | 32d28e25de1727b5ea25a36f8a96febb91ad50c8 | |
parent | 56c6213c89dfbabb21de3264ec0e024ada9fe568 (diff) | |
download | python-coveragepy-git-d8da2b9a6cf5c127c9ba9393c716d9dc4dd50cbe.tar.gz |
Keep windows working in the face of bizarre errors
-rw-r--r-- | coverage/files.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/coverage/files.py b/coverage/files.py index 5beb518d..b328f653 100644 --- a/coverage/files.py +++ b/coverage/files.py @@ -122,7 +122,9 @@ if env.WINDOWS: else: try: files = os.listdir(head) - except OSError: + except Exception: + # This will raise OSError, or this bizarre TypeError: + # https://bugs.python.org/issue1776160 files = [] _ACTUAL_PATH_LIST_CACHE[head] = files normtail = os.path.normcase(tail) |