Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

near-DST inconsistency in PST #252

Open
lukasfroehlich1 opened this issue Dec 15, 2020 · 4 comments
Open

near-DST inconsistency in PST #252

lukasfroehlich1 opened this issue Dec 15, 2020 · 4 comments

Comments

@lukasfroehlich1
Copy link

lukasfroehlich1 commented Dec 15, 2020

Hi,

I'm interested in contributing to the library but I'm unable to get the daylight savings test cases passing after pulling from master. I'm currently based in mountain time and when I update my system clock to Toronto the tests end up passing. I'm happy to take a stab at fixing the issue but would love a hint to get me started.

Thanks!

@spencermountain
Copy link
Owner

whoa!
i just reproduced this.
sorry - I thought these days were past.
Feel-free to ignore these, i will take a look at them.
Thanks for the heads-up. 😅

@spencermountain
Copy link
Owner

yeah, looks like it's #235 again - off by an hour, within an hour of a DST change:

let d = spacetime('2020-11-01T01:32:00.000-06:00')
console.log(d.time()) // 1:32am
d = d.add(30, 'minutes')
console.log(d.time() === '2:02am') // 1:02am

the tests pass in all the other locales I tried, briefly. Will take a closer look when I have some time.
cheers

@spencermountain spencermountain changed the title Test cases fail when system clock not set to Toronto near-DST inconsistency in PST Dec 18, 2020
@ericawilson9
Copy link

ericawilson9 commented Mar 9, 2021

@spencermountainwere you able to resolve this issue? Experienced this issue in production starting yesterday (Monday, March 8th, 2021)...one year after daylight savings 2020. Any insight would be greatly appreciated.

My interpretation is, It’s basically only occurring if the user device is set to CST timezone and DST is like on that day. I can’t exactly figure out the full window where this occurs. Best I can tell is it translates the wrong time the entire day of DST except for 7-9pm EST

Literally bringing my team down to our knees lol

@spencermountain
Copy link
Owner

spencermountain commented Mar 10, 2021

whoa - @ericawilson9 if you wanna join a skype call today or something, my email is spencermountain@gmail.com

yeah, I don't understand why the entire day would be effected. The only effect of this (known) bug is that people in 1-2am may think they're in 2-3am, which they would be soon, anyways. I've always understood it to be very minor.

It sounds like you're running on an older version - and this edge-case has improved since. It may be worth trying.
Let me know if I can help. The within-1-hour issue still exists, but you may be experiencing something else.
cheers

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants