How to get UTC offset for non-standard time zone names?

Xavier Ho contact at xavierho.com
Sun Jan 31 16:23:29 CET 2010


This may not answer your question directly, but have you thought about
ingoring the number at the end of these non-standard timezones? CDT is
Central Daylight-saving Timezone, while CST is Central Standard Timezone.
And you are correct they are -5 and -6 hours respectively. Does pytz know
about CDT and CST?

Cheers,
-Xav

On Mon, Feb 1, 2010 at 1:13 AM, <skip at pobox.com> wrote:

>
> I have the pytz package but it doesn't know about non-standard timezone
> names like "CDT5" or "CST6".  I can obviously infer that they are either
> five or six hours behind UTC.  Are they constructed in some standard way so
> that I can assume that if a timezone name is not known to pytz I can assume
> the trailing number represents the number of hours behind UTC?  Is there
> some standard definition of the format of such semi-numeric timezone names?
>
> Thx,
>
> --
> Skip Montanaro - skip at pobox.com - http://www.smontanaro.net/
> --
> http://mail.python.org/mailman/listinfo/python-list
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20100201/cbec5827/attachment.html>


More information about the Python-list mailing list