Derivative timezone?

Skip Montanaro skip.montanaro at gmail.com
Tue Feb 21 09:06:01 EST 2017


Is it possible to create a timezone which is a derivative of an
existing timezone? I'd like to create one which is several hours
different ahead of America/Chicago, but follows Chicago's DST changes.
My initial attempt was to create a timezone object using pytz:

tz = pytz.timezone("America/Chicago")

then add eight hours to its _utcoffset attribute, but that doesn't
work. Is "creative" timezone construction possible, or am I limited to
what pytz finds in the Olson database?

Thx,

Skip



More information about the Python-list mailing list