ropensci / tidyhydat

An R package to import Water Survey of Canada hydrometric data and make it tidy
https://docs.ropensci.org/tidyhydat
Apache License 2.0
70 stars 19 forks source link

Custom hydat download path fix #203

Open Travis-Simmons opened 7 months ago

Travis-Simmons commented 7 months ago

Previously if you supplied a 'dl_hydat_here' argument to the 'download_hydat' function it would make it all they way to the end of the function correctly, but then it calls hy_check with no argument. Which does not consider your custom path and causes an error. By supplying the path as an argument it fixes the 'download_hydat' function.

boshek commented 7 months ago

Thanks for this. The test failures here are unrelated to your PR but I think a test would be good here to have caught the change made in #181. Really this download function needs to be split into multiple small functions (though that's not your problem!).

boshek commented 6 months ago

@Travis-Simmons is writing a test for this something you'd be able to do to complete this PR?

Travis-Simmons commented 6 months ago

@boshek I am willing to write a test for it, but I am unsure how to do that! If you comment some documentation on how to write it, I will give it a go next weekend.

boshek commented 6 months ago

Actually I don't even really think it needs a test. But can you please write a NEWS entry and include your GitHub handle?

Something like this: https://github.com/ropensci/tidyhydat/blob/af345e42d10043650d66076d2d518672a21ca5f8/NEWS.md?plain=1#L30