-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Specific ruff file ignores ignore everything #3101
Comments
Do you know what version this is on? |
In #2978, we added support for directives like (Note that Flake8 treats |
Locally, my version is a bit older due to being from homebrew - 0.0.245. In pre-commit in the original issue, it should have I'll check and report back later tonight! |
So as of that PR, we do throw warnings -- e.g., if you do
|
(I think that feature shipped in 0.0.248.) |
It oddly prints the warning three times:
(And I'd be quite fine to have some sort of way to make all warnings errors). But it does work correctly, and warns as expected, in 0.0.249 (and therefore I'd assume 0.0.251)! Sorry for the noise, I should have tried an update first. |
The following file:
Shows two errors.
If I add this to the top of the file:
# ruff: noqa: F821
Then both errors disappear, instead of just one. In general, it seems that this is just a blanket noqa. (Also, this should not be too picky -
ruff: noqa F821
is an easy mistake to make! I think I'd require a#
to put a comment on the same line, if it was my choice).See pybind/pybind11#4483 (comment).
The text was updated successfully, but these errors were encountered: