Paul Ganssle <b...@m.ganssle.io> added the comment:

I think this approach is probably the best we can do, but I could also imagine 
that users might find it to be confusing behavior. I wonder if there's any 
informal user testing we can do?

I guess the ISO 8601 spec does call "Z" the "UTC designator", so 
`use_utc_designator` seems like approximately the right name. My main 
hesitation with this name is that I suspect users may think that 
`use_utc_designator` means that they *unconditionally* want to use `Z` — 
without reading the documentation (which we can assume 99% of users won't do) — 
you might assume that `dt.isoformat(use_utc_designator=True)` would translate 
to `dt.astimezone(timezone.utc).replace(tzinfo=None).isoformat() + "Z"`.

A name like `utc_as_z` is definitely less... elegant, but conveys the concept a 
bit more clearly. Would be worth throwing it to a poll or something before 
merging.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue46614>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to