Message 411713 - Python tracker (original) (raw)

I agree with Brett. Adding allow_z (or perhaps compact or use_utc_designator if we're bikeshedding) as an optional keyword only argument to .isoformat() would allow us to keep the explanation that what .fromisoformat() can parse is exactly what .isoformat() can produce, while giving a feature to .fromisoformat() that many have asked for and that would have minimal overhead in terms of code complexity or runtime performance.

Would you accept a PR that implements that, Paul?