Time('O') jumps 2hrs for Daylight Savings Time
Brought to you by:
rexx
Hi - using 3.9.0 on W7 and W8.1 Europe time zone: A call to Time('O') went from +1 hours pre-DST to +3 hours post-DST (should be +2). The documentation mentions that it can be unreliable for some OS's, so not sure whether this is a bug or a Windows issue?
Thanks,
Simon T.
If the only change in the environment is the date on which the test was run; ie Regina version the same, Windows OS the same, then it will be a Windows issue. Time('O') is determined by subtracting GMT from local time, and if DST is in effect, adds an hour. All time information is obtained from the operating system.
I don't think this is invalid. If the operating system returns the DST-corrected local time and GMT, then your 1-hour correction forces an incorrect value in Regina. This is happening tome, too. All levels of Regina from through 3.9.3 on Windows 2000 & Windows10.
Indeed, remove this code
https://stackoverflow.com/questions/46258930/
Applied as per Stefan's suggestion
TIME('O') works, but on the last day of DST it appears that TIME('T') has the same bug: