Closed mpettis closed 4 years ago
thanks for the report @mpettis ! and for including your session info. i'll have a look
Perhaps some helpful things I found on my machine:
ghcnd_stations()
, stepped into get_stations()
.ghcnd_cache$cache_path_get()
, where it intends to cache ghcnd-stations.txt
. That cache path, as of the execution of the line ff <- file.path(ghcnd_cache$cache_path_get(), "ghcnd-stations.txt")
does not yet exist.get_stations()
is executed: res <- GET_retry("ftp://ftp.ncdc.noaa.gov/pub/data/ghcn/daily/ghcnd-stations.txt",
disk = ff, ...)
My suspicion is that when ghcnd_cache
is defined in R/onload.R
, assigning it here , that directory path is expected to be created upon instantiation. But it is not.
I suspect a call to ghcnd_cache$mkdir()
is required prior to the GET_retry()
call. I'm not sure if it should go in just prior, or somewhere further up the call stack. I could do a fork and pull request if that helps you out by placing that call just prior to GET_retry()
...
thanks very much - i suspect you're right, having a look at the PR
I just downloaded this package, and am trying to use it to find weather stations near me. Using the example from here, I cannot proceed past the first step. Please advise. Below is the reprex and session info.
Session:
Created on 2020-05-13 by the reprex package (v0.3.0)