install_github ritorno di errore:zip file non può essere aperto
Domanda
quando ho eseguito le seguenti operazioni:
library(devtools)
install_github('roxygen2')
Ottengo il seguente errore:
con devtools 0.51:
Installing roxygen2 from hadley
Error in unzip(src, list = TRUE) :
zip file '/tmp/Rtmp2b44Ug/hadley-roxygen2.zip' cannot be opened
Ho installato una versione più recente (0.6) di devtools: install_github('devtools')
e l'errore è più informativo, ma simile:
> install_github('roxygen')
Installing github repo(s) roxygen/master from hadley
Installing roxygen.zip from https://github.com/hadley/roxygen/zipball
Error in expand(src, list = TRUE) :
zip file '/tmp/Rtmp2b44Ug/roxygen.zip' cannot be opened
In addition: Warning message:
In expand(src, exdir = tempdir()) : error 1 in extracting from zip file
Sto facendo qualcosa di sbagliato?
> sessionInfo()
R version 2.14.1 (2011-12-22)
Platform: x86_64-pc-linux-gnu (64-bit)
...
Soluzione
Questo errore si verifica perché la funzione install_github
set username='hadley'
per impostazione predefinita (vedere installare-github.r origine)
In questo caso, non c'è github ramo hadley/roxygen
, e ora scaricare da https://github.com/hadley/roxygen/zipball/master
Questo lavoro:
install_github('roxygen',username = 'klutometis')
nota: anche se il pacchetto si chiama roxygen2, il "repo" nome "roxygen"
Ho aperto un bug in devtools
Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow