The sqlite3 timestamp conversion between unixepoch and localtime

Michael F. Stemper michael.stemper at gmail.com
Fri Sep 3 10:55:51 EDT 2021


On 03/09/2021 01.14, Bob Martin wrote:
> On 2 Sep 2021 at 20:25:27, Alan Gauld <alan.gauld at yahoo.co.uk> wrote:
>> On 02/09/2021 20:11, MRAB wrote:
>>
>>>> In one of them (I can't recall which is which) they change on the 4th
>>>> weekend of October/March in the other they change on the last weekend.
>>>>
>>>>
>>> In the EU (and UK) it's the last Sunday in March/October.
>>>
>>> In the US it's second Sunday in March and the first Sunday in November.
>>>
>>> I know which one I find easier to remember!
>>
>> Interesting. I remember it as closer than that. The bugs we found were
>> due to differences in the DST settings of the BIOS in the PCs. (They
>> were deliberately all sourced from DELL but the EU PCs had a slightly
>> different BIOS).
>>
>> The differences you cite should have thrown up issues every year.
>> I must see if I can find my old log books...
>>
> 
> ISTR that the USA changes were the same as the EU until a few years ago.
> 
> I remember thinking at the time it changed "why would they do that?"

It was part of the Energy Policy Act of 2005[1].

However, saying that doesn't explain "why".

The explanation given at the time was that it would save energy
because people wouldn't need to turn on their lights as early.
This ignored the fact that we needed to have them on later in
the morning.

The required studies were inconclusive, but some reported that
since it was light later in the day, people went driving around
in the evening, causing aggregate energy consumption to increase
rather than decrease.

One of the bill's sponsors said that having it be light later in
the day would "make people happy".

Talk at the time (which I never verified or refuted) said that he
got significant campaign contributions from a trade group for
outdoor cooking (grills, charcoal, usw) and that they wanted it
so that the grilling season would be longer, leading to more
revenue for them.

At the time, I was product manager for real-time control systems
for critical infrastructure. Having to collect the changes to
zoneinfo, whatever the equivalent file for Oracle was, revalidate
our entire system, and get information/patches to our North American
customers was annoying.


[1] <https://www.congress.gov/bill/109th-congress/house-bill/6>, Sec 110

-- 
Michael F. Stemper
If you take cranberries and stew them like applesauce they taste much
more like prunes than rhubarb does.


More information about the Python-list mailing list