简体   繁体   中英

devtools::install_github failing in R4.0.03

I upgraded recently to R4.0.3 and devtools::install_github no longer seems to work. Eg.

> install_github('MacoskoLab/liger')
Using github PAT from envvar GITHUB_PAT
Downloading GitHub repo MacoskoLab/liger@HEAD
Error in utils::download.file(url, path, method = method, quiet = quiet,  : 
  download from 'https://api.github.com/repos/MacoskoLab/liger/tarball/HEAD' failed

or

install_github("NathanSkene/MAGMA_Celltyping")
Using github PAT from envvar GITHUB_PAT
Downloading GitHub repo NathanSkene/MAGMA_Celltyping@HEAD
Error in utils::download.file(url, path, method = method, quiet = quiet,  : 
  download from 'https://api.github.com/repos/NathanSkene/MAGMA_Celltyping/tarball/HEAD' failed

Not entirely clear to me whether it's devtools, or utils::download.file or R itself that's gone haywire here. Any suggestions welcome!

Turns out that this problem was caused by the download timing out. The repository in question is quite large (it contains datasets as well as code). There is a default 60 second timeout for install_github. Increasing this made it work:

options(timeout=9999999)
install_github("NathanSkene/MAGMA_Celltyping")

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM