Skip to content

Commit 593f420

Browse files
Add warning message for qw data queries (#134)
* add warning message for qw data queries --------- Co-authored-by: Timothy Hodson <[email protected]>
1 parent 4eba0a2 commit 593f420

File tree

2 files changed

+18
-4
lines changed

2 files changed

+18
-4
lines changed

dataretrieval/nwis.py

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,12 +126,14 @@ def get_qwdata(
126126
127127
.. warning::
128128
129-
WARNING: Beginning in February 2024 the NWIS qw data endpoint will not deliver new data or updates to existing data.
129+
WARNING: Beginning in March 2024 the NWIS qw data endpoint will
130+
not deliver new data or updates to existing data.
130131
Eventually the endpoint will be retired. For updated information visit:
131132
https://waterdata.usgs.gov.nwis/qwdata
132133
For additional details, see the R package vignette:
133134
https://doi-usgs.github.io/dataRetrieval/articles/Status.html
134-
If you have additional questions about the qw data service, email [email protected].
135+
If you have additional questions about the qw data service,
136+
135137
136138
Parameters
137139
----------
@@ -175,6 +177,12 @@ def get_qwdata(
175177
... )
176178
177179
"""
180+
warnings.warn(('WARNING: Starting in March 2024, the NWIS qw data endpoint is '
181+
'retiring and no longer receives updates. For more information, '
182+
'refer to https://waterdata.usgs.gov.nwis/qwdata and '
183+
'https://doi-usgs.github.io/dataRetrieval/articles/Status.html '
184+
'or email [email protected].'))
185+
178186
_check_sites_value_types(sites)
179187

180188
kwargs['site_no'] = kwargs.pop('site_no', sites)
@@ -758,6 +766,12 @@ def get_info(ssl_check: bool = True, **kwargs) -> Tuple[pd.DataFrame, BaseMetada
758766
"""
759767
seriesCatalogOutput = kwargs.pop('seriesCatalogOutput', None)
760768
if seriesCatalogOutput in ['True', 'TRUE', 'true', True]:
769+
770+
warnings.warn(('WARNING: Starting in March 2024, the NWIS qw data endpoint is '
771+
'retiring and no longer receives updates. For more information, '
772+
'refer to https://waterdata.usgs.gov.nwis/qwdata and '
773+
'https://doi-usgs.github.io/dataRetrieval/articles/Status.html '
774+
'or email [email protected].'))
761775
# convert bool to string if necessary
762776
kwargs['seriesCatalogOutput'] = 'True'
763777
else:

dataretrieval/wqp.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -491,8 +491,8 @@ def _warn_v3_profiles_outage():
491491
"""Private function for warning message about WQX 3.0 profiles
492492
"""
493493

494-
warnings.warn(('NEWS: USGS discrete water quality data availability '
495-
'and format are changing. Beginning in February 2024 '
494+
warnings.warn(('USGS discrete water quality data availability '
495+
'and format are changing. Beginning in March 2024 '
496496
'the data obtained from legacy profiles will not '
497497
'include new USGS data or recent updates to existing '
498498
'data. To view the status of changes in data '

0 commit comments

Comments
 (0)