A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2015-July/141055.html below:

[Python-Dev] Status on PEP-431 Timezones

[Python-Dev] Status on PEP-431 TimezonesJon Ribbens jon+python-dev at unequivocal.co.uk
Tue Jul 28 11:35:20 CEST 2015
On Mon, Jul 27, 2015 at 04:28:48PM -0700, Chris Barker wrote:
>      > The only other thing I found
>      > really weird about datetime is how Python 2 had no implementation of
>      > a UTC tzinfo class, despite this being utterly trivial -
> 
>    Huh? it is either so trivial that there is no point -- simiply say that
>    your datetimes are UTC, and you are done.
>    Or it's not the least bit trivial -- the only difference between a UTC
>    datetime and a "naive" datetime is that one can be converted to (or
>    interact with) other time zones. Except that, as we know from this
>    conversation, is very, very non-trivial!

No, it has nothing to do with conversions. The difference between a
naive timezone and a UTC one is that the UTC one explicitly specifies
that it's UTC and not "local time" or some other assumed or unknown
timezone. This can make a big difference when passing datetime
objects to third-party libraries, such as database interfaces.
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4