Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pre-commit hook for mypy is missing a bunch of actual typing problems #878

Open
edgarrmondragon opened this issue Jul 17, 2024 · 0 comments

Comments

@edgarrmondragon
Copy link
Contributor

          FWIW it seems the pre-commit hook for mypy is missing a bunch of actual typing problems, but it's probably beyond the scope of this PR to fix those:
$ mypy aiodocker tests
aiodocker/stream.py:83: error: Item "None" of "ResponseHandler | None" has no attribute "transport"  [union-attr]
aiodocker/stream.py:83: error: Item "None" of "Transport | Any | None" has no attribute "get_extra_info"  [union-attr]
aiodocker/stream.py:90: error: Argument 1 to "FlowControlDataQueue" has incompatible type "ResponseHandler | None"; expected "BaseProtocol"  [arg-type]
aiodocker/stream.py:92: error: Item "None" of "ResponseHandler | None" has no attribute "set_parser"  [union-attr]
aiodocker/stream.py:93: error: Item "None" of "ResponseHandler | None" has no attribute "force_close"  [union-attr]
aiodocker/stream.py:94: error: Incompatible types in assignment (expression has type "FlowControlDataQueue[Message]", variable has type "None")  [assignment]
aiodocker/stream.py:111: error: Item "None" of "Connection | None" has no attribute "transport"  [union-attr]
aiodocker/stream.py:112: error: Item "None" of "Transport | Any | None" has no attribute "write"  [union-attr]
aiodocker/stream.py:113: error: Item "None" of "Connection | None" has no attribute "protocol"  [union-attr]
aiodocker/stream.py:114: error: Item "None" of "ResponseHandler | Any | None" has no attribute "transport"  [union-attr]
aiodocker/stream.py:115: error: Item "None" of "ResponseHandler | Any | None" has no attribute "_drain_helper"  [union-attr]
aiodocker/stream.py:123: error: Item "None" of "Connection | None" has no attribute "transport"  [union-attr]
aiodocker/logs.py:44: error: Incompatible types in assignment (expression has type "ClientResponse", variable has type "None")  [assignment]
aiodocker/docker.py:134: error: Argument "ssl" to "TCPConnector" has incompatible type "SSLContext | None"; expected "bool | Fingerprint | SSLContext"  [arg-type]
Found 14 errors in 3 files (checked 39 source files)

Originally posted by @edgarrmondragon in #877 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant