-
-
Notifications
You must be signed in to change notification settings - Fork 310
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
Flake8 does not support typing.no_type_check #1113
Comments
In GitLab by @liiight on Nov 28, 2020, 08:41 changed the description |
In GitLab by @asottile on Nov 28, 2020, 09:15 please follow the issue template, notably:
|
In GitLab by @liiight on Nov 28, 2020, 10:11 Thanks, I apologize for opening this here |
In GitLab by @asottile on Nov 28, 2020, 10:15 an aside, I'd be very careful about using libraries which override type annotations to have custom behaviours -- they're all likely to break in python3.10 (or with |
In GitLab by @liiight on Nov 28, 2020, 10:18 hmm, good tip. I'll point the library author to it. |
In GitLab by @liiight on Nov 28, 2020, 10:32 Thanks again. I just want to point out that the wording the discenrs between flake8 and the checks that uses it could maybe be simplified or worded differently.
|
In GitLab by @liiight on Nov 28, 2020, 08:40
I am not sure if this issue is even in the scope of what flake8 can or is supposed to do. I also looked for references to this prior to opening this issue. If this was previously discussed or is completely irrelevant, I apologize in advance.
Flake8 does not seem to take into consideration the
typing.no_type_check
decorator and throwsF821 undefined name
error,Example (from Uplink's documentation, a great library with a custom use case for type annotation):
Results of running flake8:
This raises no error when running using mypy for example.
Please describe how you installed Flake8
Via pip
Note: Some *nix distributions patch Flake8 arbitrarily to accommodate incompatible software versions. If you're on one of those distributions, your issue may be closed and you will be asked to open an issue with your distribution package maintainers instead.
Please provide the exact, unmodified output of
flake8 --bug-report
Thank you in advance for your reply! Know that your efforts are highly appreciated.
The text was updated successfully, but these errors were encountered: