Ama Aje My Fren firstname.lastname@example.org added the comment:
Thanks Ezio for the detailed response.
In the list of proposed solutions in my first message, 1-3 should be quite easy to implement. This leaves us with 4-5.
To the best of my seeing there are only two places in the documentation that have information about f-strings. The tutorial and the reference I have done PR 21681 that adds index to the tutorial although searching does not seem to be better now that the reference has an index.
The lexical analysis is probably fine as is.
The introduction in the tutorial should mention f-strings ....
This is there but it _IS_ hard to find, when you don't know it is there. It may not be very "introduction-y", and if you like I can make a go at trying to reword it.
The stdtypes page is already quite long and crowded ...
True. But is this wrong? In my feeling this is reference documentation. It should be accurate, complete and clear. It may not need to be "textbook-like".
Some thoughts: - There may be benefit in reorganising stdtypes.rst to improve the flow without changing the actual content. This could mean breaking it up into a number of documents rather than the monolith it is. - It does feel like printf was plugged in later because str.format() had been explained earlier. (Although I believe printf came before str.format()). A first time reader of the document will find it hard to know the one way that is right when it comes to formatting. - f-strings should probably also be described here because it _is_ built in, no? It may not be accurate to say it is in /Lib/strings. There is no reference that a developer can just look at to remind/confirm to themselves how to "do it".
So, unless we add a separate page somewhere
This is why I was thinking of a HOWTO. Going back to your original pain in msg371912, someone wanted the f-string documentation and: -- It was hard to find. (indexing? better table of contents?) -- It was not very helpful WHEN it was found. (A second entry with f-strings in Lib that is easier for a dev to use?)
But now (and this is mainly to me) it appears that another problem is a need to consistently, clearly, and in one place describe the various elements/nuances/eccentricities of presenting data in Python: - string - string.Formatter, - string.Template, - str.format() - f-string - Format Specification Mini-Language - maybe even __format__ and conversion? - etc
I propose one of the following two: 1) A new section in Library documentation just to handle strings, then systematically removing them elsewhere.(Built-In Functions, Built-In Types, Text Processing Services) 2) We take all that Python history and explain it in a HOWTO, and add a developer friendly reference in the Library for f-string. More like Logging Cookbook rather than Logging Howto.
!) above is similar to what you propose ... but different-ish.
 https://docs.python.org/dev/tutorial/inputoutput.html#formatted-string-liter...  https://docs.python.org/dev/reference/lexical_analysis.html#f-strings  https://docs.python.org/dev/search.html?q=fstring  https://docs.python.org/dev/search.html?q=f-string  https://docs.python.org/dev/library/stdtypes.html#printf-style-bytes-formatt...  https://docs.python.org/dev/library/stdtypes.html#str.format