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
$ pip install flake8==6.0.0
flake8 --bug-report
{ "platform": { "python_implementation": "CPython", "python_version": "3.8.10", "system": "Linux" }, "plugins": [ { "plugin": "mccabe", "version": "0.7.0" }, { "plugin": "pycodestyle", "version": "2.10.0" }, { "plugin": "pyflakes", "version": "3.0.0" } ], "version": "6.0.0" }
Imports used only for type hinting via # type to be detected as used and not be highlighted by flake8 as unused.
# type
from typing import Dict gaz = {} # type: Dict[int, int]
$ flake8 test/test.py test/test.py:1:1: F401 'typing.Dict' imported but unused
The text was updated successfully, but these errors were encountered:
Use type annotations on class attributes
fd932df
This is a workaround for PyCQA/flake8#1755, but also a shift towards the bright Python 3 future.
In the future, please search closed and open issues before creating new ones that are duplicates.
Sorry, something went wrong.
No branches or pull requests
how did you install flake8?
$ pip install flake8==6.0.0
unmodified output of
flake8 --bug-report
describe the problem
what I expected to happen
Imports used only for type hinting via
# type
to be detected as used and not be highlighted by flake8 as unused.sample code
commands ran
The text was updated successfully, but these errors were encountered: