Skip to content

v1.2.0

Latest

Choose a tag to compare

@thodson-usgs thodson-usgs released this 24 Jun 21:24
4daf771

v1.2.0 is a major release. It adds two new data modules — wateruse (USGS National Water Availability Assessment Data Companion) and ngwmn (National Ground-Water Monitoring Network) — both built on a new, API-agnostic OGC engine; migrates the HTTP layer from requests to httpx (unlocking the async, auto-chunked waterdata fan-out); and unifies every module's request failures under a single DataRetrievalError exception taxonomy. It also lands the breaking changes the 1.x line had been deferring: Python 3.10+ is now required, services are accessed through their submodules rather than the flattened top-level namespace, get_samples parameters are snake_case (camelCase still accepted via a shim), and the deprecated nadp / samples shims and NWIS_Metadata.variable_info are removed. Alongside these, a large batch of reliability fixes harden the waterdata OGC getters (chunking, DST handling, error surfacing) and repair wqp / nldi / streamstats edge cases.

Breaking changes

  • Require Python >=3.10 and remove the deprecated NWIS_Metadata.variable_info property by @thodson-usgs in #332
  • Access services via their submodules instead of the flattened top-level namespace by @thodson-usgs in #315
  • Unify request failures under a DataRetrievalError taxonomy by @thodson-usgs in #313
  • Refine the error taxonomy to a lean, idiomatic form by @thodson-usgs in #319
  • snake_case the get_samples parameters (camelCase kept via a shim) by @thodson-usgs in #331
  • Remove the nadp module and the deprecated samples shim by @thodson-usgs in #330
  • Return (df, BaseMetadata) from get_codes by @thodson-usgs in #301
  • Migrate the HTTP layer from requests to httpx by @thodson-usgs in #289

New modules and features

Reliability and bug fixes

  • Naive datetime filters shifted an hour across the DST boundary by @thodson-usgs in #307
  • numpy array / Series numeric params leaked their repr into the query by @thodson-usgs in #308
  • Raise RequestTooLarge for an unchunkable over-budget request instead of a silent 414 by @thodson-usgs in #309
  • Preserve leading zeros on WQP code columns (HUCs, parameter codes, FIPS) by @thodson-usgs in #311
  • Drop id from the wire properties so daily / continuous don't 400 by @thodson-usgs in #323
  • Gate the chunked fan-out with a semaphore, not the connection pool by @thodson-usgs in #322
  • get_ratings — don't abort on one bad feature, don't silently truncate by @thodson-usgs in #304
  • Repair WQP_Metadata.site_info and streamstats.Watershed by @thodson-usgs in #295
  • Repair WQP_Metadata.site_info (was always None) by @thodson-usgs in #305
  • Return an empty GeoDataFrame instead of crashing on empty nldi results by @thodson-usgs in #302
  • Coherent error handling and safe cleanups for the non-OGC getters by @thodson-usgs in #298
  • Stop nwis emitting a DeprecationWarning at import time by @thodson-usgs in #300
  • Small coherence cleanups (annotations, column order, defensiveness) by @thodson-usgs in #306

Docs, testing, and hygiene

Full Changelog: v1.1.5...v1.2.0