Reputation: 1
I'm looking for a way to configure a linter (such as Ruff or another popular Python linter) to disallow double assignments in single lines, like this:
name, position = files.name, pos
Instead, I want the linter to enforce separate assignments on separate lines, like this:
name = files.name
position = pos
However, I still want to allow tuple unpacking, like this:
name, position = extract_details()
Is there a way to configure a linter to achieve this behavior? If so, how can I do it?
Upvotes: 0
Views: 136