GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||
GeezerVison is showing github.com — ci: check types with mypy by muggenhor · Pull Request #1226 · gitpython-developers/GitPython Conversation
Contributor
This is intended to (partially) address the CI concerns expressed in #1219 and #1223 and will result in partial type checking of the type annotations by using mypy. Keep in mind though that mypy is performing best-effort static analysis in a dynamically typed language so it can only partially check for correctness. Some other tool(s) will be needed to have more complete type checking at runtime. E.g. typeguard. In order to get mypy running successfully this also makes a few (as little as possible) changes to the type annotations. The mypy setting to require annotations on everything is commented out because there's way too much functions lacking annotations right now.
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. All reactions
Member
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page.
Contributor
Author
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. Without the presence of 'test-requirements.txt' 'tox' is unusable. Because there's too many to fix quickly. This gives mypy all information that it needs to determine what the return type of a function call is *iff* it knows the argument's type. As a result it can now stop complaining about passing None to str.join() in exc.py. By telling it where it's imported from in one case and telling it to ignore it in another. This will result in _partial_ type checking of the type annotations by using mypy. Keep in mind though that mypy is performing _static_ analysis in a _dynamic_ language so it can only partially check for correctness. Some other tool(s) will be needed to have more complete type checking at runtime. E.g. [typeguard]. [typeguard]: https://pypi.org/project/typeguard/
|
There was an error while loading. Please reload this page.
|
Rebased (to force test-rerun) after #1227 got merged. Unfortunately it looks like the 3.9 build failed due to what looks like an intermittent failure. And I cannot retrigger a build without (another) force push.... |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Thanks a million! |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.