reader::type_convert() is used after all the batches are stacked on top of each other. This way, batches cannot have incompatible data types as they’re combined. (#257; thanks @isaactpetersen #245) Consequently, the
guess_max parameter in
redcap_read() no longer serves a purpose, and has been soft-deprecated. (#267)
httr::content() (which is inside
kernel_api()) now processes the returned value as “text/csv”, by default. This should prevent strange characters from tricking the process as the internal variable
raw_text is being formed. See the [httr::content()
](https://httr.r-lib.org/reference/content.html) documentation for a list of possible values for thecontent_type` parameter. (Thanks to great debugging by @vortexing #269, @sybandrew #272, & @begavett, #290)
redcap_next_free_record_name(): API call for ‘Generate Next Record Name’, which returns the next available record ID (Issue #237)
redcap_read_oneshot()allow the user to specify if all variables should be returned with the
characterdata type. The default is to allow
readr::read_csv()to guess the data type. (#194)
redcap_read_oneshot()allows use to specify how many rows should be considered when
readr::read_csv()guesses the data type. (#194)
redcap_read_oneshot_eav()always return Linux-style line endings (ie
\n) instead of Windows style line endings (ie,
\r\n) on all OSes. (#198)
charactervectors for all variables. With readr 1.2.0, some column were returned differently than before. (#193)
redcap_users_export()now included (#163)
redcap_read_oneshot_eav()(#206). It was already implemented for
constants()) easily exposes REDCap-specific constants. (#217)
id_positionallows user to specify if the record_id isn’t in the first position (#207). However, we recommend that all REDCap projects keep this important variable first in the data dictionary.
redcap_read_oneshot()are more consistent with the order in raw REDCap API. (#204)
verboseparameter is NULL, then the value from getOption(“verbose”) is used. (#215)
guess_maxparameter provided in
redcap_read()(no longer just
redcap_read_oneshot()). Suggested by @isaactpetersen in #245.
redcap_variables()now throws an error when passed a bad URI (commit e542155639bbb7).
kernal_api()function, which uses the ‘httr’ and ‘curl’ packages underneath. Until now, each function called those packages directly. (#213)
readr::read_csv()is used instead of
odbcpackage to retrieve credentials from the token server. Remove RODBC and RODBCext (#188). Thanks to @krlmlr for error checking advice in https://stackoverflow.com/a/50419403/1082435.
base:stop()) (#190 & #208).
collapse_vector()is refactored and tested (#209)
retrieve_credential_mssql()is more general and more useful.
retrieve_credential_local(). These transition from storing & retrieving just the token (ie,
retrieve_token_mssql()) to storing & retrieving more information.
retrieve_credential_local()facilitates a standard way of storing tokens locally, which should make it easier to follow practices of keeping it off the repository.
data.table::rbindlist()is used. This should prevent errors with the first batch’s data type (for a column) isn’t compatible with a later batch. For instance, this occurs when the first batch has only integers for
record_id, but a subsequent batch has values like
aa-test-aa. The variable for the combined dataset should be a character. (Issue #128 & http://stackoverflow.com/questions/39377370/bind-rows-of-different-data-types; Thanks @arunsrinivasan)
dplyrpackage instead of
plyr. This shouldn’t affect callers, because immediately before returning the data,
tibble::tibble(which was formerly called
dplyr::tbl_df) back to a vanilla
curlpackage, instead of
readcap_read()is being used without ‘Full Data Set’ export privileges. The problem involves the record IDs are hashed.
id_positionin the first stage of batching. The metadata needed to be read before that, after the updates for REDCap Version 6.0.x.
retrieve_token_mssql()uses regexes to validate parameters
redcap_metadata_read()are tested and public.
testthat::skip_on_cran()before any call involving OUHSC’s REDCap server.
redcap_write_oneshot()are now tested and public.
redcap_write_oneshot()are now tested and public.
redcap_download_file_oneshot()function contributed by John Aponte (@johnaponte; Pull request #35)
redcap_upload_file_oneshot()function contributed by @johnaponte (Pull request #34)
verbose==TRUE. Follows advice of @johnaponte, Benjamin Nutter (@nutterb), and Rollie Parrish (@rparrish). Closes #43.
records_collapseddefault empty value is now an empty string (i.e.,
"") instead of
NULL. This applies when
records_collapsedis either a parameter, or a returned value.
redcap_download_file_oneshot()documentation, thanks to Andrew Peters (@ARPeters #45).
httrpackage, which provides benefits like the status code message can be captured (eg, 200-OK, 403-Forbidden, 404-NotFound). See https://cran.r-project.org/package=httr.
outcome_message. This is because the message associated with http code returned is conventionally called the ‘status messages’ (eg, OK, Forbidden, Not Found).
raw_textvalue (which was formerly called
raw_csv) is returned as an empty string to save RAM. It’s not really necessary with httr’s status message exposed.
redcap_read(). These changes reflect our suggestion that reads should typically be batched.
redcap_write_oneshot()(which is an internal function).