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

refactor: fetch by default #156

Merged
merged 15 commits into from
Aug 30, 2023
Merged

refactor: fetch by default #156

merged 15 commits into from
Aug 30, 2023

Conversation

dshemetov
Copy link
Contributor

@dshemetov dshemetov commented Aug 25, 2023

closes #144
closes #119

  • fetch_args_list() has these arguments, open to better/clearer naming suggests
#' @param fields a list of epidata fields to return, or NULL to return all
#'  fields (default) e.g. c("time_value", "value") to return only the
#' time_value and value fields or c("-direction") to return everything except
#' the direction field
#' @param disable_date_parsing disable automatic date parsing
#' @param disable_data_frame_parsing disable automatic conversion to data frame; this
#'   is only supported by endpoints that only support the 'classic' format (non-tabular)
#' @param return_empty boolean that allows returning an empty tibble if there is no data
#' @param timeout_seconds the maximum amount of time to wait for a response
#' @param base_url base URL to use
#' @param make_call boolean that allows skipping the call to the API and instead
#'  returns the `epidata_call` object (useful for debugging)
#' @param debug boolean that allows returning the raw response from the API
#' @param format_type the format to request from the API, one of classic, json, csv; this
#'  is only used by `fetch_debug`

TODO:

  • look over the vignette text to make sure it still reads right

@dshemetov dshemetov changed the title partial feat: fetch_args_list refactor: fetch by default Aug 25, 2023
@dshemetov dshemetov marked this pull request as ready for review August 26, 2023 00:16
@dsweber2
Copy link
Contributor

dsweber2 commented Aug 29, 2023

Generally pretty happy with this, made a number of small docs changes. To keep the format of the flags the same (i.e. they're all off by default), maybe make_call should be dry_run or something like that?

I separated fetch_args_list into a separate reference page, because all the parameters of create_epidata_call, fetch and fetch_args_list were mixed together.

@dshemetov dshemetov merged commit 7f2d73a into dev Aug 30, 2023
6 checks passed
@dshemetov dshemetov deleted the ds/merge-fetch branch August 30, 2023 18:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants