-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Formatter collapses last call in call chaining #7051
Comments
Black uses Ruff's formatting in preview style if the left is a multiline string but it seems they keep the old formatting otherwise playground To me it's unclear if expanding the last call is intentional to improve readability. I'm inclined to keep Ruff's formatting because it achieves the goal of avoiding unnecessary horizontal lines but it depends on how frequent we run into this difference (although could be hard to fix) |
This was not frequent for me, but tbh I'm curious why. The pattern looks like it could be in some exploratory scripts we have. I'll dig more next week. |
We're going to mark this as a known deviation for now. We'll revisit based on user feedback, but it's not blocking for the beta. (We can close the issue itself for now once this is documented.) |
## Summary I missed this in the prior pass. Closes #7051.
I prefer the change, but reporting since it's a diff in a from-
black
migration.Line-length: 88
Related: #5343
Black (23.7.0):
Ruff (0.0.287):
Counter example
Playground: https://play.ruff.rs/02424913-15b0-4703-8eb8-6bc5896b00b6
The text was updated successfully, but these errors were encountered: