[docs] "sane" tzinfo subclasses
paulkoning at comcast.net
Thu Sep 29 03:13:06 CEST 2011
On Sep 28, 2011, at 7:49 PM, Senthil Kumaran wrote:
> On Sun, Sep 18, 2011 at 09:04:16PM -0400, Paul Koning wrote:
>> Section 8.1.6 of the library manual talks about
>> utcoffset(dt)-dst(dt) as the "standard offset" and says that this
>> should not depend on the date or time but only on the location.
> What would be good note to add to explain that? IIRC, someone at the
> top when dealing with datetime and timezones Python docs already
> mentions that it cannot be relied up completely, because timezone
> rules changes sometimes due to politics of the land.
I would just get rid of that statement, because it isn't supported by the reality of how timezones are defined.
The larger question is in the doc's claim that datetime.astimezone() relies on this assumption. Does it really? If yes, why? Given that the assumption is not valid, is astimezone() in fact broken?
That's possibly a code issue rather than a doc issue (if the doc correctly stated the dependence).
More information about the docs