question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Popular timezone sometimes doesn't work

See original GitHub issue

Some popular timezones like PST doesn’t work because it’s not in the TIMEZONES in config file https://github.com/EddieJaoudeCommunity/EddieBot/blob/46b1e136b749113b2f871b553189e6a55c8c158f/src/config.ts#L30-L36

And some existing timezone that has more than three characters like AEST wont work because the regular expression matches 2 to 3 characters only [a-zA-Z]{2,3}, it should match 2 to 4 characters. https://github.com/EddieJaoudeCommunity/EddieBot/blob/46b1e136b749113b2f871b553189e6a55c8c158f/src/timezone.ts#L20

- const match = message.content.match(/([\d]{1,2})([:\d]{3})?[\s]?(pm|am|AM|PM)?\b[\s]([a-zA-Z]{2,3})?\b/);
+ const match = message.content.match(/([\d]{1,2})([:\d]{3})?[\s]?(pm|am|AM|PM)?\b[\s]([a-zA-Z]{2,4})?\b/);

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:7 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
Vyvy-vicommented, Oct 12, 2020

Should I do a longitude sweep to cover major time zones in each zone?

0reactions
BOLT04commented, Oct 12, 2020

maybe we could add a package to get popular timezones, but I don’t know… add the ones you think are important 👍

Read more comments on GitHub >

github_iconTop Results From Across the Web

"Set time zone automatically" does not work. Why and how to
Go to Search. Type Data and Time. Open it. · Click on Internet Time tab. · Click on Change settings. · Check Synchronize...
Read more >
How to Fix It When the Time on Your Phone Is Wrong - Lifewire
The most likely reason is that the time zone is misconfigured, either because you set it manually or incorrectly. When the wrong time...
Read more >
Time zone issues - how to deal with them in the IT project?
Every time zone can be defined as an offset from UTC (in hours, sometimes not full hours). Let's look at some popular ones....
Read more >
There's a time zone bug in iOS and iPadOS. Here's what to do ...
Having issues with your iPhone, iPad, or iPod not updating your time zone? Learn different stategies to fix these time zones issues in...
Read more >
Time zone does not update automatically - Apple Community
Go to Settings/General/Date & Time and make sure you have Set Automatically turned on. Also go to Settings/Privacy/Location Services. Make sure ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found