You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
and it may be difficult to distinguish intentionally/manually added noqa and those automatically added.
I think, main use case is migration to ruff for existing codebase without fixing everything at once, but it should be clear that those noqa added automatically and should be handled at some point, something like that:
# noqa: S308 FIXME when you are here
Downside of it - adding longer comment will produce more formatting changes, so, perhaps
# noqa: S308 auto
or even ruff may have some argument for provide the text of comment.
The text was updated successfully, but these errors were encountered:
Do you really want to # noqa them if you intend to fix them?
Yes, first of all it makes it much more visible - when you read the code you see that lines you are touching can be improved - ruff is working on file level, so linter can show issues in lines you are not intended to touch. Also, marking all existing issues as noqa really simplifies to see new issues, approach with number of errors also may work in average, but same time it might be you fixed two old, but introduced a new.
Something like #1149 may also be useful.
Hi!
Ruff can automatically add
noqa
directives, but they don't have any info about how they were added:and it may be difficult to distinguish intentionally/manually added
noqa
and those automatically added.I think, main use case is migration to ruff for existing codebase without fixing everything at once, but it should be clear that those
noqa
added automatically and should be handled at some point, something like that:Downside of it - adding longer comment will produce more formatting changes, so, perhaps
or even ruff may have some argument for provide the text of comment.
The text was updated successfully, but these errors were encountered: