Inconsistent method chaining #1723
Labels
F: linebreak
How should we split up lines?
R: duplicate
This issue or pull request already exists
T: style
What do we want Blackened code to look like?
black
currently formats method chaining inconsistently. It should always produce the more readable option.Examples in the current Black style
This is ugly and hard to read:
This occurs only sometimes
With longer method chaining, the more readable format is generated:
Desired style:
It would be nice if the more readable format was always produced in the first case above. It would be easier to read and more consistent.
On a related note, sometimes method chains are broken up in a way that harms readability, the suggested format above would be auto-formatted to a less readable version below
The desired format would be the same in this case, as it is clearly more readable to have arguments appear next to the functions they are passed to.
The text was updated successfully, but these errors were encountered: