Almost of this module is from the official documentation of datetime module in Python standard library.
(Utc, datetime.timezone) The tzinfo instance that represents UTC. It’s an instance of Utc in Python 2 (which provide no built-in fixed-offset tzinfo implementation), and an instance of timezone with zero offset in Python 3.
Fixed offset in minutes east from UTC.
>>> kst = FixedOffset(9 * 60, name='Asia/Seoul') # KST +09:00 >>> current = now() >>> current datetime.datetime(2013, 8, 15, 3, 18, 37, 404562, tzinfo=libearth.tz.Utc()) >>> current.astimezone(kst) datetime.datetime(2013, 8, 15, 12, 18, 37, 404562, tzinfo=<libearth.tz.FixedOffset Asia/Seoul>)
In most cases, it doesn’t need to be directly instantiated: there’s already the utc value.
Guess the most commonly used time zone from the given locale.
the most commonly used time zone, or None if can’t guess
New in version 0.3.0.