-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
FURB188 can apply to any slice regardless of the slice’s step. FURB188 should only apply if the step is omitted, None, 1, or True.
$ ruff --version
ruff 0.6.5
$ cat furb188.py
text = "!x!y!z"
if text.startswith("!"):
text = text[1::2]
print(text)
$ python furb188.py
xyz
$ ruff check --isolated --preview --target-version py39 --select FURB188 furb188.py --fix
Found 1 error (1 fixed, 0 remaining).
$ python furb188.py
x!y!zReactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working