Issue metadata
Sign in to add a comment
|
new Date instance from UTC date with timezone shifts the timezone by extension the day value
Reported by
tiran...@gmail.com,
Jun 8 2018
|
||||||||||||||||||||||||
Issue description
UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:60.0) Gecko/20100101 Firefox/60.0
Steps to reproduce the problem:
1. new Date("1958-06-14T00:00:00.0000000+02:00").toString()
2. outputs "Fri Jun 13 1958 23:00:00 GMT+0100 (Central European Summer Time)"
What is the expected behavior?
Expected behaviour is outputting "Fri Jun 14 1958 00:00:00 GMT+0200 (Central European Summer Time)"
What went wrong?
The timezone modifier seems to shift to +01:00 instead of +02:00. I think it might have to do with daylight savings time.
Did this work before? Yes Version before this Chrome update (66 was the main version number, don't remember the exact version)
Chrome version: 67.0.3396.79 (Official Build) (64-bit) Channel: stable
OS Version: 10.0
Flash Version:
Might have to change system time to match Amsterdam with the Win10 option to automatically set daylight savings time turned on
,
Jun 9 2018
,
Jun 11 2018
This issue seems similar to Issue 850876 , hence merging into it and marking it as Duplicate. Note: Feel free to un-dupe it if not the case. Thanks!
,
Jun 11 2018
I don't think it's a duplicate of 850876, since that seems to have something to do with an issue specific to London.
,
Jun 14 2018
My guess is that your problem is that Amsterdam transitioned to daylight saving in 1977. In June 1958 there was no daylight saving and it was therefore only 1 hour different from UTC, rather than the 2 of today - and so GMT+0100 is correctly reflecting that. Refer https://www.timeanddate.com/time/zone/netherlands/amsterdam. My understanding is that this is how dates now work in chrome and as per the ECMA 262 spec - the UTC offsets are based on the date in question rather than using the current (as in now) offset. I agree that this is correct - and that other major browsers are now wrong - but whilst this is "correct" in practice it is a pain. Possibly this is a candidate for there to be an option in date handling to "use old/broken timezone offset". |
|||||||||||||||||||||||||
►
Sign in to add a comment |
|||||||||||||||||||||||||
Comment 1 by tiran...@gmail.com
, Jun 8 2018