unmatched-suppression-comment (RUF104)
Added in 0.15.0 · Related issues · View source
What it does
Checks for unmatched range suppression comments
Why is this bad?
Unmatched range suppression comments can inadvertently suppress violations over larger sections of code than intended, particularly at module scope.
Example
Use instead:
def foo():
# ruff: disable[E501]
REALLY_LONG_VALUES = [...]
# ruff: enable[E501]
print(REALLY_LONG_VALUES)