We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
from typing import TYPE_CHECKING if TYPE_CHECKING: Alias = MyClass else: Alias = object class MyClass: pass
On mypy 1.3.0 (https://mypy-play.net/?mypy=latest&python=3.10&gist=5f2c9b8d93c4b97a57d385c3511f23b3) produces:
main.py:4: error: Name "MyClass" is used before definition [used-before-def]
Perhaps the check should be fully suppressed within if TYPE_CHECKING blocks.
if TYPE_CHECKING
The text was updated successfully, but these errors were encountered:
This is a duplicate of #14539.
Sorry, something went wrong.
No branches or pull requests
On mypy 1.3.0 (https://mypy-play.net/?mypy=latest&python=3.10&gist=5f2c9b8d93c4b97a57d385c3511f23b3) produces:
Perhaps the check should be fully suppressed within
if TYPE_CHECKING
blocks.The text was updated successfully, but these errors were encountered: