You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Black and Ruff formatted this code differently - I don't think this is a Known Deviation and could't find an similar issue.
Both are readable but I actually prefer what black is doing here on YELLOWSTONE_CAMPSITE_AVAILABILITY and YELLOWSTONE_PROPERTY_INFO. I prefer the variable name and the type annotation on the same line as opposed to the variable name, annotation, and value on three separate lines. I also prefer the parentheses to be around the value instead of the annotation.
I came across the issue when moving from black to ruff on a large code base. Everything else looked perfect!
🤦 yep, you're right @MichaReiser. I was using my global ruff which was at 0.0.292 instead of my project's ruff (0.1.3). Everything looks perfect now. Really fantastic work.
Summary
Black and Ruff formatted this code differently - I don't think this is a Known Deviation and could't find an similar issue.
Both are readable but I actually prefer what
black
is doing here onYELLOWSTONE_CAMPSITE_AVAILABILITY
andYELLOWSTONE_PROPERTY_INFO
. I prefer the variable name and the type annotation on the same line as opposed to the variable name, annotation, and value on three separate lines. I also prefer the parentheses to be around the value instead of the annotation.I came across the issue when moving from black to ruff on a large code base. Everything else looked perfect!
Original Code
Code after
black
Code After
ruff format
Note that both the
original
and theblack
code will be changed to thisSettings
ruff==0.1.3
black==23.3.0
The text was updated successfully, but these errors were encountered: