Skip to content

Conversation

@ehinman
Copy link
Collaborator

@ehinman ehinman commented Jun 12, 2025

This small PR adds a filtering step to the get_gwlevels function that ensures only the requested pcodes are returned. For whatever reason, the "new" gwlevels endpoint doesn't seem to recognize the parameterCd argument, even though it is still specified in the documentation: https://nwis.waterservices.usgs.gov/docs/groundwater-levels/groundwater-levels-details/

See Issue #179

@ehinman ehinman marked this pull request as ready for review June 12, 2025 17:10
@thodson-usgs thodson-usgs added the upstream bug Upstream API isn't working label Jun 13, 2025
@thodson-usgs
Copy link
Collaborator

Looks good to me. Normally, we should avoid patching the upstream API; however, this is a shorterm fix until the nwis services are deprecated.

@ehinman ehinman merged commit 0e6167f into DOI-USGS:main Jun 13, 2025
6 of 11 checks passed
Copy link

@BojanMilinic BojanMilinic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code itself looks good and all the checks at least pass on windows. I am interested in the "Did you mean to use assert instead of return?" error for the Ubuntu runs.

@ehinman
Copy link
Collaborator Author

ehinman commented Jun 16, 2025

The code itself looks good and all the checks at least pass on windows. I am interested in the "Did you mean to use assert instead of return?" error for the Ubuntu runs.

Thanks for identifying this bug with the services and taking a look, @BojanMilinic. @thodson-usgs and I plan to address this testing issue in a subsequent PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

upstream bug Upstream API isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants