Comments (7)
from hydrotools.
from hydrotools.
Thanks Shengting.
I successfully reproduced the error with the following:
from hydrotools.nwis_client.iv import IVDataService
service = IVDataService(value_time_label="value_time")
obs = service.get(
sites=["01189000"],
startDt="2015-12-01T00:00",
endDt="2015-12-31T23:45"
)
The error seems to originate here:
Looks like the issue is when NWIS returns an empty time series it results in an empty pandas.DataFrame
. A KeyError
is raised when the tool attempts to optimize the float values. As I recall, older versions of nwis_client
would check for this using pandas.DataFrame.empty
before attempting any optimizations. It looks like this functionality may have been lost during the asyncio
transition.
I'll ping @aaraney for input.
from hydrotools.
@stcui007, thanks for reporting this and thanks @jarq6c for verifying and reproducing the bug. I was able to reproduce it locally as well. I believe your thinking is correct @jarq6c, some logic was changed in #86. I will submit a PR and reference it here. Thanks!
from hydrotools.
from hydrotools.
@stcui007, no worries. My apology if I implicitly suggested that you needed to do anything. This was just a bug in the software. #134 should resolve the issue.
from hydrotools.
Fix has been deployed:
https://pypi.org/project/hydrotools.nwis-client/3.0.5/
@stcui007 @aaraney @hellkite500
from hydrotools.
Related Issues (20)
- NWIS IV Client `FutureWarning` HOT 3
- NWM Client New Test Failure: AttributeError: 'EntryPoints' object has no attribute 'get' HOT 5
- Pandas >= 2.0.0 package compliance audit HOT 4
- `nwis_client` "sqlite3.OperationalError: database is locked" HOT 6
- Move `hydrotools` namespace packages to separate repositories HOT 3
- "Run Slow Unit Tests" Action has been failing for some time HOT 2
- 3.7 Tests failing: xarray EntryPoints has no attribute get HOT 6
- DeprecationWarning: Deprecated call to `pkg_resources.declare_namespace HOT 1
- AWS Retrospective HOT 10
- SVI Client slow unit tests failing HOT 8
- nwm_client_new documentation is incomplete for private servers. HOT 1
- nwm_client_new `get` methods fails with custom Parquet Store
- Consider supporting MS Azure (`nwm_client_new`) HOT 1
- Determine feasibility of _restclient's continued dependence on `aiohttp_cache_client` HOT 5
- SVI Client get method failing due to Pydantic>2 issue HOT 1
- New version of `_restclient` cannot be pushed to PyPI b.c. namespace packages with leading `_` in package name cannot be uploaded HOT 1
- Add some basic information about the NWM operational configuration to the `nwm_client_new` package. HOT 1
- Event Detection methods are raising `FutureWarning` HOT 3
- question about update cycle for hydrotools HOT 3
- NWPS API Available HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from hydrotools.