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

Installation failure #87

Closed
Kanyerezi30 opened this issue Jun 7, 2022 · 5 comments
Closed

Installation failure #87

Kanyerezi30 opened this issue Jun 7, 2022 · 5 comments

Comments

@Kanyerezi30
Copy link

Hello here,
I am using R version 4.2.0 and I have failed to install the package. Below is the error message

Downloading GitHub repo outbreak-info/R-outbreak-info@HEAD Error in utils::download.file(url, path, method = method, quiet = quiet, : download from 'https://api.github.com/repos/outbreak-info/R-outbreak-info/tarball/HEAD' failed

@flaneuse
Copy link
Contributor

flaneuse commented Jun 7, 2022

@Kanyerezi30 thanks for the note. Are you using a Windows system? It looks like there may be some issues with using the remotes package (which is the source of the install_github command) with https requests.

RStudio has a series of suggestions. It sounds like adding this option worked for Windows users with other package installs:

options(download.file.method = "wininet")

Please let us know if this resolves the issue. Thanks!

@Kanyerezi30
Copy link
Author

I am using Ubuntu 18.04

@flaneuse
Copy link
Contributor

flaneuse commented Jun 7, 2022

Did you try adding options(download.file.method = "libcurl") as suggested in the RStudio article? I think this is an issue with the remotes package and https requests.

@Kanyerezi30
Copy link
Author

Thank you @flaneuse for your support

I have finally figured it out. Below is the procedure I have taken

On the command line:
git clone https://github.com/outbreak-info/R-outbreak-info.git sudo apt install libudunits2-dev sudo apt install libgdal-dev

In R:
install.packages("units", dependencies = T) install.packages("sf", dependencies = T) devtools::install_local("<path/to/repo/folder>")

It's working perfectly well now

@flaneuse
Copy link
Contributor

flaneuse commented Jun 7, 2022

Ah, glad you were able to figure it out! The sf installation can be a bit finicky -- maps in R always come with a hiccup or two. Thanks for posting the working solution.

@flaneuse flaneuse closed this as completed Jun 7, 2022
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