Skip to content

Commit e669cd7

Browse files
committed
feat: API key rollout is done! no warning errors
1 parent f121d72 commit e669cd7

File tree

1 file changed

+0
-16
lines changed

1 file changed

+0
-16
lines changed

R/epidatacall.R

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -184,22 +184,6 @@ fetch_classic <- function(epidata_call, fields = NULL, disable_data_frame_parsin
184184
response <- request_impl(epidata_call, "classic", fields)
185185
response_content <- httr::content(response, as = "text", encoding = "UTF-8")
186186

187-
# TODO Temporary workaround the first row of the response being a comment
188-
# Remove on 2023-06-21
189-
if (grepl("This request exceeded", response_content) && !epidata_call$only_supports_classic) {
190-
response_content <- jsonlite::fromJSON(response_content, simplifyDataFrame = FALSE)
191-
message <- response_content$epidata[[1L]]
192-
cli::cli_abort(c(
193-
"epidata warning, promoted to error: {message}",
194-
"i" = "Either:",
195-
"*" = "set the environment variable DELPHI_EPIDATA_KEY, or",
196-
"*" = 'set the option "delphi.epidata.key":',
197-
" " = '{.code options(delphi.epidata.key = "YOUR_KEY_OR_TEMP_KEY")}',
198-
"To save your key for later sessions (and hide it from your code), you can edit your .Renviron file with:",
199-
"*" = "usethis::edit_r_environ()"
200-
))
201-
}
202-
203187
response_content <- jsonlite::fromJSON(response_content, simplifyDataFrame = !disable_data_frame_parsing)
204188

205189
# success is 1, no results is -2, truncated is 2, -1 is generic error

0 commit comments

Comments
 (0)