mirror of
https://github.com/Tautulli/Tautulli.git
synced 2025-07-16 02:02:58 -07:00
Update pytz-2021.3
This commit is contained in:
parent
d76838a607
commit
9d78e6ae4c
122 changed files with 327 additions and 278 deletions
|
@ -22,8 +22,8 @@ from pytz.tzfile import build_tzinfo
|
|||
|
||||
|
||||
# The IANA (nee Olson) database is updated several times a year.
|
||||
OLSON_VERSION = '2019c'
|
||||
VERSION = '2019.3' # pip compatible version number.
|
||||
OLSON_VERSION = '2021c'
|
||||
VERSION = '2021.3' # pip compatible version number.
|
||||
__version__ = VERSION
|
||||
|
||||
OLSEN_VERSION = OLSON_VERSION # Old releases had this misspelling
|
||||
|
@ -34,7 +34,7 @@ __all__ = [
|
|||
'NonExistentTimeError', 'UnknownTimeZoneError',
|
||||
'all_timezones', 'all_timezones_set',
|
||||
'common_timezones', 'common_timezones_set',
|
||||
'BaseTzInfo',
|
||||
'BaseTzInfo', 'FixedOffset',
|
||||
]
|
||||
|
||||
|
||||
|
@ -111,6 +111,13 @@ def open_resource(name):
|
|||
def resource_exists(name):
|
||||
"""Return true if the given resource exists"""
|
||||
try:
|
||||
if os.environ.get('PYTZ_SKIPEXISTSCHECK', ''):
|
||||
# In "standard" distributions, we can assume that
|
||||
# all the listed timezones are present. As an
|
||||
# import-speed optimization, you can set the
|
||||
# PYTZ_SKIPEXISTSCHECK flag to skip checking
|
||||
# for the presence of the resource file on disk.
|
||||
return True
|
||||
open_resource(name).close()
|
||||
return True
|
||||
except IOError:
|
||||
|
@ -263,8 +270,8 @@ def _UTC():
|
|||
module global.
|
||||
|
||||
These examples belong in the UTC class above, but it is obscured; or in
|
||||
the README.txt, but we are not depending on Python 2.4 so integrating
|
||||
the README.txt examples with the unit tests is not trivial.
|
||||
the README.rst, but we are not depending on Python 2.4 so integrating
|
||||
the README.rst examples with the unit tests is not trivial.
|
||||
|
||||
>>> import datetime, pickle
|
||||
>>> dt = datetime.datetime(2005, 3, 1, 14, 13, 21, tzinfo=utc)
|
||||
|
@ -683,6 +690,7 @@ all_timezones = \
|
|||
'America/North_Dakota/Beulah',
|
||||
'America/North_Dakota/Center',
|
||||
'America/North_Dakota/New_Salem',
|
||||
'America/Nuuk',
|
||||
'America/Ojinaga',
|
||||
'America/Panama',
|
||||
'America/Pangnirtung',
|
||||
|
@ -1050,6 +1058,7 @@ all_timezones = \
|
|||
'Pacific/Guam',
|
||||
'Pacific/Honolulu',
|
||||
'Pacific/Johnston',
|
||||
'Pacific/Kanton',
|
||||
'Pacific/Kiritimati',
|
||||
'Pacific/Kosrae',
|
||||
'Pacific/Kwajalein',
|
||||
|
@ -1210,7 +1219,6 @@ common_timezones = \
|
|||
'America/Fort_Nelson',
|
||||
'America/Fortaleza',
|
||||
'America/Glace_Bay',
|
||||
'America/Godthab',
|
||||
'America/Goose_Bay',
|
||||
'America/Grand_Turk',
|
||||
'America/Grenada',
|
||||
|
@ -1264,6 +1272,7 @@ common_timezones = \
|
|||
'America/North_Dakota/Beulah',
|
||||
'America/North_Dakota/Center',
|
||||
'America/North_Dakota/New_Salem',
|
||||
'America/Nuuk',
|
||||
'America/Ojinaga',
|
||||
'America/Panama',
|
||||
'America/Pangnirtung',
|
||||
|
@ -1412,7 +1421,6 @@ common_timezones = \
|
|||
'Australia/Adelaide',
|
||||
'Australia/Brisbane',
|
||||
'Australia/Broken_Hill',
|
||||
'Australia/Currie',
|
||||
'Australia/Darwin',
|
||||
'Australia/Eucla',
|
||||
'Australia/Hobart',
|
||||
|
@ -1506,7 +1514,6 @@ common_timezones = \
|
|||
'Pacific/Chuuk',
|
||||
'Pacific/Easter',
|
||||
'Pacific/Efate',
|
||||
'Pacific/Enderbury',
|
||||
'Pacific/Fakaofo',
|
||||
'Pacific/Fiji',
|
||||
'Pacific/Funafuti',
|
||||
|
@ -1515,6 +1522,7 @@ common_timezones = \
|
|||
'Pacific/Guadalcanal',
|
||||
'Pacific/Guam',
|
||||
'Pacific/Honolulu',
|
||||
'Pacific/Kanton',
|
||||
'Pacific/Kiritimati',
|
||||
'Pacific/Kosrae',
|
||||
'Pacific/Kwajalein',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue