date_time_parser
date_time_parser copied to clipboard
Support more timezones
Currently this only supports US timezones. It would be great to parse more timezones.
https://en.wikipedia.org/wiki/List_of_time_zone_abbreviations
I could to that, I think. Do you mean to add all zones from the list? What about duplicate abbreviations, such as AMT?
Doesn't have to be all of them, but as many as you can manage. If you're going to choose some, I'd chose timezones that have more population.
For duplicate timezones, I think it'd be safest to not parse those since can be ambiguous, and maybe a future PR can provide an option to specify the timezone.
Here are the duplicates that I see:
- AMT
- ACT = OK to parse as Acre Time, not ASEAN Common Time since that's unofficial.
- AST
- BST (aww man.. )
- CDT is already parsed as Central Daylight Time, not Cuba Daylight Time
- CST is already parsed as Central Standard Time, not China Standard Time nor Cuba Standard Time.
- ECT
- GST
- IST
- LHST
- MST is already parsed as Mountain Standard Time, not Malaysia Standard Time.
- SST
Heads up, there is some logic to determine a timezone abbreviation vs AM/PM, which may complicate things for timezones with the letter M as a second letter. If you want to skip those, that's ok with me and we get follow-up in a later PR to cover those.