-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Closed
Labels
stubs: false positiveType checkers report false errorsType checkers report false errors
Description
It seems that the re.compile
types are to restrictive, the following code errors in mypy but running it is no problem:
# _txt_fmt is a object gotten from `re.compile`
with open(file, 'r+') as f:
with mmap.mmap(f.fileno(), 0) as data:
match = _txt_fmt.match(data)
Mypy gives the error Argument 1 to "match" of "Pattern" has incompatible type "mmap"; expected "bytes"
.
Metadata
Metadata
Assignees
Labels
stubs: false positiveType checkers report false errorsType checkers report false errors