Replies: 1 comment 1 reply
-
I like the idea mostly to (hopefully) make it easier for new developers to contribute code that matches our contribution guidelines. It's possible that it would make things more complicated and harder for new developers though. So I'd love to hear others thoughts about this. I just saw the |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
In PR #379 @ethanbass added a new function
try_url()
which is essentially a wrapper aroundhttr::RETRY()
where some commonly used arguments are fixed. @Aariq suggested we could use this or a similar function for allhttr::RETRY()
querries in webchem. The issue I see with the current version is that quite often we use "POST" instead of "GET" and/or add some extra arguments. I think these limitations could be easily circumvented with the following structure:Variations (not necessarily always but at least once):
config = httr::config(accept_encoding = "identity")
httr::add_headers(headers)
andbody = body
httr::add_headers(.headers = headers)
andbody = body
and sometimes use "POST"httr::write_disk(path, overwrite = TRUE)
handle = handle('')
andbody = body
body = paste0("inchi=", query)
,body = paste0(from, "=", query)
What do you think of this approach?
Beta Was this translation helpful? Give feedback.
All reactions