-
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 removes line break between implicitly concatenated strings #7052
Comments
Black applies special formatting for strings inside binary expressions. We have a "cheap" implementation that works for the most simple cases but it falls short in more complicated settings. I hope to have a fix for this by next week. |
We're marking this as an intentional deviation, since the resulting code doesn't exceed line width and reduces vertical spacing. (If you make the strings longer, we do split and format identically to Black.) Can be closed once documented. |
Couldn't find an exact issue, but I'm almost certain this has been reported already.
Maybe related to #6936
Also see #5893
Line-length: 88
Black (23.7.0):
Ruff (0.0.287):
Playground: https://play.ruff.rs/126e4315-3c75-4268-b43a-12586c5da779
The text was updated successfully, but these errors were encountered: