Skip to content

Automatic Daylight Saving and Date Adjustments #21

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

Draft
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

alairon
Copy link
Contributor

@alairon alairon commented May 6, 2023

Pull request checklist

Please check if your PR fulfills the following requirements:

  • Docs have been reviewed and added / updated if needed (for bug fixes / features)
  • Build (npm run build) was run locally and any changes were pushed
  • Lint (npm run lint) has passed locally and any fixes were made for failures

Pull request type

Please check the type of change your PR introduces:

  • Bugfix
  • Feature
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • Documentation content changes
  • Other (please describe):

What is the current behavior?

  • The RegionTimeZoneMapping variable is manually updated some time after Daylight Saving occurs for NA and EU servers, which unfortunately occurs on different Sundays (2nd/1st Sundays of March/Nov respectively for NA, and last Sundays of March and Oct for EU). South American servers are most likely not affected by DST.

  • Users looking at events happening the following day after the page loads will always initially be told that events are happening "in 23 hours". This is because time is calculated relative to when the user initially accessed the page.

  • The automatic date changer changes dates when the local current time hits midnight. Users living in time zones that do not line up with the selected server's time zone may experience unexpected behavior when either the local or server date changes.
    Note that these issues can currently be resolved manually by clicking on the date button, or by refreshing the page

    • Users with local times that changes the date ahead of the server will have events skipped
    • If the server changes the date ahead of the user's local time, the date will not automatically change and new events are not shown

What is the new behavior?

Improved automation

  • Changed the dropdowns to now automatically adjust based on whether the server's time zone has experienced Daylight Saving. Server locations are based on the assumption of the IANA TZ database codes from the AWS EC2 server host cities. This improves resiliency in case future legislation is enacted to modify DST for those cities.
  • Changed the selected date's reference point to midnight server time
  • The automatic date changer will now switch dates when the server does

Does this introduce a breaking change?

  • Yes
  • No

@vercel
Copy link

vercel bot commented May 6, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
lostarktimer ✅ Ready (Inspect) Visit Preview 💬 Add feedback May 6, 2023 4:34am

@alairon
Copy link
Contributor Author

alairon commented May 9, 2023

image
I just realized that this PR isn't as effective as it could've been. Someone over at AGS or SG still doesn't know when DST happens

@alairon alairon marked this pull request as draft May 15, 2023 04:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant