-
Notifications
You must be signed in to change notification settings - Fork 4
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
Time zone capital or lowercase #96
Comments
While PR #145 address a lot of the timezone handling, The solution to this would be to have |
There is a |
Alternatively you could use a little filter to match the input string against the available from Example for 'mst' as given string, will return 'MST' import re
pattern = re.compile('^mst$', re.I)
next(filter(pattern.match, pytz.all_timezones)) |
Would this make users lazy in not looking up the actual timezone name? Just passing the string through is working now with minimal changes. The gotcha is that |
I am mainly suggesting a case-insensitive lookup of the user input. Has the additional advantage that it is checked against valid ones and can catch errors early |
Fully understand. We need to figure out what is better, case insensitive or not? |
You make a good point regards enforcing/educating users to lookup proper timezone names. |
For down the road: USDA-ARS-NWRC/inicheck/issues/53 |
The
time_zone
value in the config file has to specifically be from thepytz
list with correct captial case. For example,mst
does not work butMST
does. However,utc
works when it should beUTC
so somewhere SMRF is modifying the value.https://stackoverflow.com/questions/13866926/is-there-a-list-of-pytz-timezones
The text was updated successfully, but these errors were encountered: