-
Notifications
You must be signed in to change notification settings - Fork 0
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
getUSGS fails when recent measurement is not available in lookback window #24
Comments
Hmm...in troubleshooting this I could not replicate. The gage is fixed and errors from similar non transmitting gages are being handed gracefully. I guess I will just keep my eyes open if it happens again. This was the original error I got on the server:
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
If the USGS gage stops transmitting and there recent no measurements available, the getUSGS script fails on line 182 in the getUSGS_ts function. The getUSGS function expects a
name
element in thetimeseries
attribute returned by the USGS API. The USGS API returns a blank array in this case. This causes the script to fail and not process any other USGS sites in the queue.Code expects this:
![image](https://private-user-images.githubusercontent.com/9432394/400483406-d15509cc-3e87-4f91-97e5-14de9b776a8b.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzk0NTgwNjQsIm5iZiI6MTczOTQ1Nzc2NCwicGF0aCI6Ii85NDMyMzk0LzQwMDQ4MzQwNi1kMTU1MDljYy0zZTg3LTRmOTEtOTdlNS0xNGRlOWI3NzZhOGIucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI1MDIxMyUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNTAyMTNUMTQ0MjQ0WiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9MzE5OWFkN2FiZWE3NThiNzcxY2UyMjkwZmJlNGZmYzIwMzg5MDRhODJmNzM0NzUxOTM2OGFhZjBkYWUwZDU1YyZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QifQ.bgw5QxhLTnxWSN97PtAvfK2HlrFSNy9kTxflzwuE-z0)
But gets this:
![image](https://private-user-images.githubusercontent.com/9432394/400483226-b8a446ac-0428-4070-904d-b533db501eaf.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzk0NTgwNjQsIm5iZiI6MTczOTQ1Nzc2NCwicGF0aCI6Ii85NDMyMzk0LzQwMDQ4MzIyNi1iOGE0NDZhYy0wNDI4LTQwNzAtOTA0ZC1iNTMzZGI1MDFlYWYucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI1MDIxMyUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNTAyMTNUMTQ0MjQ0WiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9OWUyODk1Yzk0MTVlZTM2MDI4YWMyYjliYWM1YWFjMWU1MjI0ZTE1ZmU5NGQ4ODA4ZTdmNDY0NWZhYzUyNzJiNiZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QifQ.JK_BCJk4a9Ronsh8o48AZp6Lf37WwL0ZyjTONvjhBVI)
The text was updated successfully, but these errors were encountered: