Re:Black: An uncompromising Python code formatter
by ben509 on Friday May 25, 2018 @05:52PM
(#17158320)
I agree about the noise, but, it's much easier to work with. raise FooException("Can't load bar") works, as does f"The flange is elevated by {flange['spronge']} degrees of spronge."
[ Parent
| on HN ]
Re:Black: An uncompromising Python code formatter
by mixmastamyk on Friday May 25, 2018 @07:45PM
(#17159118)
Goes both ways, sometimes there's text to quote:
raise KeyError('"%s" not found.' % name)
f'The flange is elevated by {flange["spronge"]} degrees of spronge.'
I don't normally use many contractions or possessives in my code, but am willing to admit it happens occasionally.