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

Error when passing httr options #307

Closed
BastienRance opened this issue Sep 15, 2020 · 2 comments
Closed

Error when passing httr options #307

BastienRance opened this issue Sep 15, 2020 · 2 comments

Comments

@BastienRance
Copy link

Hello,
Thank you very much for this package. It is such a great way to interact with REDCap!

REDCapR is returning an error when using Curl options.

Code:

redcap_read_oneshot(redcap_uri=uri,
                                token=token,
                                config_options = httr::config(ssl_verifypeer = 0L, ssl_verifyhost = 0L)
  )

Response:

Error in redcap_read_oneshot(redcap_uri = uri, token = token, config_options = httr::config(ssl_verifypeer = 0L,  : 
  Assertion on 'config_options' failed: Must have length 1, but has length 7.

This code used to work very well.

The error is launched by this line: checkmate::assert_list( config_options , any.missing=TRUE , len=1, null.ok=TRUE)
Is the length of the list supposed to be one ?

Thank you very much for your help.

REDCap version: 10.0.14
REDCapR version: 0.11.0
OS: linux

wibeasley added a commit that referenced this issue Sep 15, 2020
@wibeasley
Copy link
Member

@BastienRance, yeah, your'e right. I didn't realize the len parameter is a little different than for other checkmate functions. I just removed that length constrains from the dev branch (not the master). Can you see if that fixes this issue?

If so, I'll push to the master in a few days. There were some small tidyverse changes underneath that create havoc in the test suite. The diagnostic messages are just different enough to fail the checks.

@BastienRance
Copy link
Author

Works like a charm! Thank you very much.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants