On Tue, 14 Mar 2017, Lu Feng wrote:

I noticed that the UNIX time from timelocal() started to differ from that you 
get from using DateTime module, for dates earlier than 11/6/1910.
 
For the America/New_York local timezone, timelocal() thinks there was a DST 
switch on 11/6/1910, while DateTime module thinks there was none.

I'm pretty sure timelocal() is wrong here, though I'm not sure why. There was no DST transition in that zone in 1910. In fact, there wasn't really a time zone until 1918. The pre-1918 zone file in the Olson database is just using local solar time, but it's not very meaningful. If you really care about local times in the early 1900s you probably need to calculate the solar noon for the given lat/long.


Cheers,

Dave Rolsky
http://blog.urth.org
https://github.com/autarch

Reply via email to