datetime.stdptime help
Mike Driscoll
kyosohma at gmail.com
Wed May 28 17:22:49 EDT 2008
On May 28, 12:19 pm, mblume <mbl... at socha.net> wrote:
> Am Tue, 27 May 2008 12:37:34 -0700 schrieb Dennis Lee Bieber:
>
> > From the library reference:
> > """
> > Support for the %Z directive is based on the values contained in tzname
> > and whether daylight is true. Because of this, it is platform-specific
> > except for recognizing UTC and GMT which are always known (and are
> > considered to be non-daylight savings timezones). """
>
> > The only value that passed for me was UTC (I didn't try GMT) but...
>
> For me, only UTC, GMT, CET and CEST (Central European [Summer] Time) work.
> My time.tzname is ('CET', 'CEST').
> I think the documentation must be read that ***only***
> UTC,GMT,time.tzname work.
>
> Also, time zone names are not unique: EST can be Eastern Summer Time (US)
> as well as Eastern Summer Time (Australia).
>
> For working with time zones, I think that a module like pytzhttp://pytz.sourceforge.net/
> may be better suited.
>
> My 0.02c.
> Martin
Yeah. The timezone part of Python's time module is probably it's
weakest link. There was a pretty long thread about it about a year
ago. Maybe 2.6 or the 3.0 branch will make it a little more friendly.
Mike
More information about the Python-list
mailing list