time.strftime Timezone issue

Allen Unueco allen at premierweb.com
Sat Jun 12 21:42:51 EDT 2004


Never mind,

I just looked at Modules/timemodule.c and now I realize it that 
time.strftime() is just a wrapper for the c library function of the same 
name.

I guess I'll just live with my 'time.tzname[time.daylight]' code.

-allen


Allen Unueco wrote:
> I feel that the '%Z' format specifier from strftime() returns the wrong 
> value when daylight savings is in effect.
> 
> Today the following is always true:
> time.strftime('%Z') == time.tzname[0]
> 
> Shouldn't it be:
> time.strftime('%Z') == time.tzname[time.daylight]
> 
> -allen



More information about the Python-list mailing list