Author akira
Recipients akira, belopolsky
Date 2014-08-21.23:45:20
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1408664720.86.0.544786788738.issue22241@psf.upfronthosting.co.za>
In-reply-to
Content
I don't see, how it is a duplicate. Everything works if pytz.utc (.tzname() == 'UTC')
is used instead of timezone.utc (.tzname() == 'UTC+00:00').
Everything works if UTC class from the example [1] 
in the tzinfo docs is used.
It only breaks due to the weird timezone.utc.tzname() return value.

[1] https://docs.python.org/3.4/library/datetime.html#datetime.tzinfo.fromutc

Why does datetime.now(timezone.utc).strftime('%Z')
(via timezone.utc.tzname(dt)) produce 'UTC+00:00'?
How is it motivated?
Is it documented somewhere?
Can datetime.now(timezone.utc).strftime('%Z') be changed to return 'UTC'?
History
Date User Action Args
2014-08-21 23:45:20akirasetrecipients: + akira, belopolsky
2014-08-21 23:45:20akirasetmessageid: <1408664720.86.0.544786788738.issue22241@psf.upfronthosting.co.za>
2014-08-21 23:45:20akiralinkissue22241 messages
2014-08-21 23:45:20akiracreate