DOI-USGS / dataRetrieval

This R package is designed to obtain USGS or EPA water quality sample data, streamflow data, and metadata directly from web services.
https://doi-usgs.github.io/dataRetrieval/
Other
259 stars 84 forks source link

Avoid partial matching on the headerInfo attribute of webservice objects #534

Closed jsta closed 3 years ago

jsta commented 3 years ago

I get a warning on running the first example for readNWISqw:

readNWISqw In attr(doc, "header") : partial match of 'header' to 'headerInfo'

Under the hood getWebServiceData.r sets an attribute headerInfo but subsequent lines in importRDB1.r and readNWISqw.r read from the header attribute (instead of headerInfo) via partial matching. While partial matching doesn't cause an error in this case, it might in the future. I have a PR prepared to read explicitly from headerInfo and avoid this warning.

You may not see the same warning unless you have the following set in your .Rprofile:

warnPartialMatchAttr = TRUE