-
Notifications
You must be signed in to change notification settings - Fork 14
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
CDA can't handle Timezones that don't exist anymore (or at all) #987
Comments
It's trying to convert because the date types aren't strings internally, so we can validate user input. However; in this case we clearly forgot we store a bunch of odd edge cases. All of those should be changed from US/Pacific-New as that was never actually adopted and it's an official timezone, but in that particular case I think we should also work around it in CDA. |
That reminds me, there's also some "USGS", or maybe it was SHEF, timezones we support by name as well. They should also be translated. @perrymanmd any other time zone in database edge cases we've forgotten about? |
The SHEF time zones and their equivalents used by the python SHEF parser are shown below.
|
It seems like @ktarbet ran across "AST" in USGS data for Puerto Rico and it was being treated as Alaska Standard Time, but I don't remember the details. |
The CWMS schema contains timezones that either never existed (placeholders), or no longer exist in the host system (java runtime).
As such, any attempt to retrieve locations fails with the following:
In the CWMS schema, there are several timezone entries that trigger this:
There may be others, those are just the two I encountered.
Code example uses cwms-python, but that shouldn't matter, just make a request to the /locations endpoint using an internal CDA instance (not the national/public):
Expectations
I don't know why it's trying to convert the timezone for location retrieval, when it's not even needed.
I'd expect the /locations endpoint to work fine, perhaps printing a warning in the log, not erroring out entirely.
The text was updated successfully, but these errors were encountered: