This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author sobolevn
Recipients eric.smith, ezio.melotti, iritkatriel, r.david.murray, sobolevn
Date 2021-09-13.12:04:47
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
> I think that would require some major surgery to the code, but would be worth it.

I've decided to take an easy path:

                     "Invalid format specifier: '%s' for object of type '%s'",
                     PyUnicode_AsUTF8AndSize(format_spec, NULL),

This worked for me as the starting point. It covered: int, float, complex, and str types.

> Note that in your original example, you want the error to contain "{length:%HH:%MM}". By the time the error is detected, the only thing the code knows is the format specifier "%HH:%MM". It doesn't know the "length" part. 

I guess it has changed since the 2014.

I would love to hear any feedback on my proposal and improve it to the level when it can be merged :)
Date User Action Args
2021-09-13 12:04:47sobolevnsetrecipients: + sobolevn, eric.smith, ezio.melotti, r.david.murray, iritkatriel
2021-09-13 12:04:47sobolevnsetmessageid: <>
2021-09-13 12:04:47sobolevnlinkissue20524 messages
2021-09-13 12:04:47sobolevncreate