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

RCurl::url.exists() inconsistency between macOS/Windows #31

Closed
ablaette opened this issue Feb 16, 2021 · 2 comments
Closed

RCurl::url.exists() inconsistency between macOS/Windows #31

ablaette opened this issue Feb 16, 2021 · 2 comments

Comments

@ablaette
Copy link
Collaborator

The GermaParl package throws an issue when trying to download GermaParl from Zenodo. Apparently, this is an issue with RCurl::url.exists().

The following code returns TRUE on macOS but (falsely) FALSE on Windows.

tarball <- "https://zenodo.org/api/files/0953ee44-a31f-4177-b5c9-b48eb4ddbd96/germaparl_v1.0.6.tar.gz"
RCurl::url.exists(tarball)

As a consequence, you can download GermaParl on macOS but not on Windows. And we have a CRAN issue:
https://www.r-project.org/nosvn/R.check/r-devel-windows-ix86+x86_64/GermaParl-00check.html

So this needs to be fixed soon.

@ablaette
Copy link
Collaborator Author

I think we can avoid this error by using httr::http_error() rather than RCurl::url.exists(). See:
https://stackoverflow.com/questions/31420210/r-check-existence-of-url-problems-with-httrget-and-url-exists

@ablaette
Copy link
Collaborator Author

Switched to httr::http_error() which apparantly solves the issue.

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

1 participant