Skip to content

Unnecessary parentheses when fix PLC2801 #14597

@bebound

Description

@bebound

ruff check a.py --select PLC2801 --fix --preview --unsafe-fixes changes the code from

assert 'kk'.__str__() == 'kk'

to

assert (str('kk')) == 'kk'

expected behavior: assert str('kk') == 'kk'

My ruff version is 0.8.0

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingfixesRelated to suggested fixes for violations

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions