Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pub_covid_hosp_state_timeseries issue column, and likely related endpoints/columns, are not parsed successfully #202

Closed
brookslogan opened this issue Nov 1, 2023 · 1 comment · Fixed by #220
Assignees
Labels
bug Something isn't working

Comments

@brookslogan
Copy link
Contributor

library(epidatr)
covid_hosp_timeseries_selection <-
  pub_covid_hosp_state_timeseries("ak", as.Date("2022-12-17"))
covid_hosp_timeseries_selection$issue
#> [1] NA
# VS:
response <-
  pub_covid_hosp_state_timeseries("ak", as.Date("2022-12-17"), fetch_args = fetch_args_list(dry_run = TRUE)) |>
  epidatr:::request_url() |>
  httr::GET()
httr::content(response)$epidata[[1]]$issue
#> [1] 20231027

Created on 2023-11-01 with reprex v2.0.2

@brookslogan brookslogan added the bug Something isn't working label Nov 1, 2023
@brookslogan
Copy link
Contributor Author

Workaround: disable_date_parsing = TRUE in fetch_args_list, then convert the impacted columns with e.g.

            date = as.Date(as.character(date), format="%Y%m%d"),
            issue = as.Date(as.character(issue), format = "%Y%m%d"),

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants