News for hackers. Stuff that matters.
Re:Python 3's F-Strings: An Improved String Formatting Syntax by dagenix on Wednesday January 20, 2021 @11:09PM (#25855280)
As the sibling comment points out, it actually doesn't work that way. The first parameter is only treated as a format string _if_ there are arguments. If not, it is treated as a literal string: https://github.com/python/cpython/blob/dcea78ff53d02733ac598...
Re:Python 3's F-Strings: An Improved String Formatting Syntax by ploxiln on Thursday January 21, 2021 @12:23AM (#25855754)
I stand corrected. Thanks.

(That's what I get for assuming consistent behavior :P)

Re:Python 3's F-Strings: An Improved String Formatting Syntax by dagenix on Thursday January 21, 2021 @01:32AM (#25856157)
I only found out about this quirk a few months ago immediately after I had given the same warning you had to someone else. It's extremely unintuitive.