Fix line number for decorator issues by hauntsaninja · Pull Request #18392 · python/mypy (original) (raw)
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 andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Conversation3 Commits1 Checks17 Files changed
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
[ Show hidden characters]({{ revealButtonHref }})
Diff from mypy_primer, showing the effect of this PR on open source code:
antidote (https://github.com/Finistere/antidote)
- tests/core/test_inject.py:548: error: Unused "type: ignore" comment [unused-ignore]
- tests/core/test_inject.py:549: error: Argument 1 to "method" of "Inject" has incompatible type "Callable[[], object]"; expected "Callable[[Any], object]" [arg-type]
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This makes sense. I assume the end line is at the actual def ...
line?
end line is the same, just matches end_lineno provided by the python ast
hauntsaninja added a commit to hauntsaninja/mypy that referenced this pull request
Fixes python#17655
The decorator cleanup moves a type ignore, but so does the bug fix in python#18392 , so might as well batch into a single release
hauntsaninja added a commit that referenced this pull request
Fixes #17655
The decorator cleanup moves a type ignore, but so does the bug fix for decorators in #18392 , so might as well batch into a single release
2 participants