Skip to content

Commit 65286e8

Browse files
authored
Merge branch 'master' into mypybot/sync-typeshed
2 parents f94dd65 + 46595ee commit 65286e8

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

mypy/build.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2140,6 +2140,7 @@ def parse_file(self, *, temporary: bool = False) -> None:
21402140
# other systems, but os.strerror(ioerr.errno) does not, so we use that.
21412141
# (We want the error messages to be platform-independent so that the
21422142
# tests have predictable output.)
2143+
assert ioerr.errno is not None
21432144
raise CompileError(
21442145
[
21452146
"mypy: can't read file '{}': {}".format(

mypy/modulefinder.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -777,6 +777,7 @@ def get_search_dirs(python_executable: str | None) -> tuple[list[str], list[str]
777777
print(err.stdout)
778778
raise
779779
except OSError as err:
780+
assert err.errno is not None
780781
reason = os.strerror(err.errno)
781782
raise CompileError(
782783
[f"mypy: Invalid python executable '{python_executable}': {reason}"]

0 commit comments

Comments
 (0)