When debug specifier _and_ format_spec are present, use !s as the conversion default#63
When debug specifier _and_ format_spec are present, use !s as the conversion default#63davepeck wants to merge 1 commit intolysnikolaou:tstringsfrom davepeck:tstring-debug-expr-fix
format_spec are present, use !s as the conversion default#63Conversation
|
I think that's a spec issue. Having I'm wondering now how we can change the spec with the PEP having been accepted. |
I’ll open a PR and find out. 😅 Annoyed at myself for not catching this earlier — I've been trying to go over spec vs implementation in detail and this is the first thing I’ve run across with the spec. Luckily it’s pretty minor. |
The intent is that "Accepted" is different from "Final" to allow for changes made during the implementation of the feature |
Oh got it. Thanks for the clarification! |
|
Closing without merge in favor of the PR on PEP750 |
Currently,
t"{1=:foo}".interpolations[0]isInterpolation(1, '1', None, 'foo').The section of PEP750 on the debug specifier says it should be
Interpolation(1, '1', 's', 'foo').Assuming we think the spec is right, here's a fix. (Otherwise, LMK and I'll fix the PEP.)