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

install_github fails is a release note for every release #37

Open
revodavid opened this issue Nov 17, 2014 · 22 comments
Open

install_github fails is a release note for every release #37

revodavid opened this issue Nov 17, 2014 · 22 comments
Assignees

Comments

@revodavid
Copy link
Contributor

Several users report that install_github is failing on Ubuntu 14.04:
https://groups.google.com/forum/?utm_medium=email&utm_source=footer#!msg/rropen/GeCyC-wfWA4/r9lvM2s8uRMJ

> library(devtools)
> devtools::install_github("twitter/BreakoutDetection")
Downloading github repo twitter/BreakoutDetection@master
Error in system(full, intern = quiet, ignore.stderr = quiet, ...) : 
  error in running command

As a workaround, install_git appears to work:

> devtools::install_github("smbache/magrittr", ref = "dev")
Downloading github repo smbache/magrittr@dev
Error in system(full, intern = quiet, ignore.stderr = quiet, ...) : 
  error in running command
> devtools::install_git("git://github.com/smbache/magrittr.git", branch = "dev")
@revodavid
Copy link
Contributor Author

It seemed possible that this was a bug in the 2014-10-1 version of devtools on the MRAN snapshot, but it worked fine for me on MacOS:

> install.packages("devtools")
also installing the dependencies ‘bitops’, ‘httr’, ‘RCurl’, ‘memoise’, ‘whisker’, ‘rstudioapi’, ‘jsonlite’

[snip]

> install_github("twitter/BreakoutDetection")
Downloading github repo twitter/BreakoutDetection@master
Installing BreakoutDetection
Installing dependencies for BreakoutDetection:
Rcpp, ggplot2, Rcpp
also installing the dependencies ‘colorspace’, ‘dichromat’, ‘munsell’, ‘labeling’, ‘plyr’, ‘gtable’, ‘reshape2’, ‘scales’, ‘proto’

[snip]

* installing *source* package ‘BreakoutDetection’ ...
** libs
clang++ -I/Library/Frameworks/R.framework/Resources/include -DNDEBUG  -I/usr/local/include -I/usr/local/include/freetype2 -I/opt/X11/include -DPLATFORM_PKGTYPE='"mac.binary.mavericks"' -I"/Library/Frameworks/R.framework/Versions/3.1/Resources/library/Rcpp/include"   -fPIC  -Wall -mtune=core2 -g -O2  -c RcppExports.cpp -o RcppExports.o

[snip]
** testing if installed package can be loaded
* DONE (BreakoutDetection)

@cmosetick
Copy link
Contributor

@revodavid I confirm that this issue is still present on Ubuntu 14.04. I tested inside a fresh RRO Ubuntu docker container.

devtools::install_github("twitter/BreakoutDetection") does not work.
Only this command worked:
devtools::install_git("git://github.com/smbache/magrittr.git", branch = "dev")

I then tested this on the last RRO Ubuntu 14.04 build artifact from 8.0.1 beta from November 13th and it still does not work.

I tested this on RRO for Mac as well. I made sure that I was using the 2014-10-01 snapshot and
devtools::install_github("twitter/BreakoutDetection")
worked fine for me there.

@andrie andrie added this to the Sprint 2 milestone Dec 10, 2014
@revodavid
Copy link
Contributor Author

Please retest in 8.0.1-beta3

@sfweller
Copy link

This is still a problem in 8.0.1 beta3. It looks to me like the problem is due to differences in how the system() command is invoked on Ubuntu systems. Will look at this issue more closely to verify exactly where the problem is.

@sfweller
Copy link

I have determined what the source of the problem is - the issue has been reported here on Hadley's github website:
r-lib/devtools#406

The problem is that on Ubuntu systems, you get the following:

getOption("unzip")
[1] " "

whereas 'install_github()' expects:

getOption('unzip')
[1] "internal"

A quick fix for customers is to simply set:
options(unzip = 'internal')

After doing this it works.

Do we want to doc this or add this to our notes?

@dkarlov
Copy link

dkarlov commented Mar 17, 2015

This problem also occurred on suse 12.2

@revodavid
Copy link
Contributor Author

@dkarlov, can you tell us what the result of getOption("unzip") is on your system? Setting options(unzip="internal") should work around the problem, but I am unsure whether RRO is behaving differently to R in this regard,

@dkarlov
Copy link

dkarlov commented Mar 17, 2015

getOption("unzip")
[1] ""

@dkarlov
Copy link

dkarlov commented Mar 17, 2015

install_git worked perfectly

@revodavid
Copy link
Contributor Author

A call do install_git of this form also works around the issue:

devtools::install_git("https://github.com/ramnathv/htmlwidgets.git", branch = "master")

@revodavid
Copy link
Contributor Author

It was included in the release notes for 3.2.0 and should be included in release notes for future versions until the issue is resolved.

@j-martens j-martens removed the wontfix label May 26, 2015
@j-martens j-martens added this to the 3.2.1.0 milestone May 26, 2015
@j-martens j-martens assigned nathansoz and j-martens and unassigned nathansoz May 26, 2015
@j-martens
Copy link
Contributor

In every release, add the following to the release notes:

Known Issues

@j-martens j-martens removed the OS Linux label Jun 6, 2015
@j-martens
Copy link
Contributor

@j-martens j-martens removed this from the 3.2.1.0 milestone Jun 6, 2015
@mtelesha
Copy link

Just wanted to also state like dkarlov reported on March 12 that OpenSUSE has an issue. I am using OpenSUSE 13.2 and it failed.

options(unzip = 'internal') did fix it for OpenSUSE 13.2

@j-martens
Copy link
Contributor

Thank you, @mtelesha
We'll make note of it in the release notes.

@j-martens j-martens changed the title install_github fails on Ubuntu 14.04 install_github fails is a release note for every release Jul 24, 2015
@aaronthor
Copy link

Hi, just wanted to report that:

require(devtools)
install_github('ramnathv/rCharts')
Downloading github repo ramnathv/rCharts@master
Error in system(full, intern = quiet, ignore.stderr = quiet, ...) :
error in running command

still doesn't work in Ubuntu 14.04 X64..
Although:

install_git('https://github.com/ramnathv/rCharts.git')

works, it leads to issues when uploading to shinyapps.io with the following errors:

   Preparing to deploy application...DONE
   Uploading bundle for application: 61854...Error: 
   * Unable to deploy package dependency 'rCharts'
    The package was installed locally from source. Only packages
    installed from CRAN, BioConductor and GitHub are supported.
  Execution halted 

Thanks

@sfweller
Copy link

Hi Aaron,

This is a known issue and we should document this in our release.
To workaround the issue, you can do the following in R, BEFORE calling install_github():

options(unzip = 'internal')

Hope this helps.

Stephen Weller
Revolution R Open Technical Support

@aaronthor
Copy link

Hello Stephen,

Appreciate your response with the workaround. Unfortunately, I had to drop
out of my Coursera course as I wasn't able to submit my final project..
Will try with the workaround when I get home this evening. Thank you.

Have a marvelous day ahead Stephen!

Cheers,
Aaron

On Tue, Sep 29, 2015 at 6:07 AM, Stephen Weller notifications@github.com
wrote:

Hi Aaron,

This is a known issue and we should document this in our release.
To workaround the issue, you can do the following in R, BEFORE calling
install_github():

options(unzip = 'internal')

Hope this helps.

Stephen Weller
Revolution R Open Technical Support


Reply to this email directly or view it on GitHub
#37 (comment)
.

@j-martens
Copy link
Contributor

Hello!

As you may now know, this is a known devtools issue (not an RRO issue). The workaround Stephen mentioned is documented earlier in this thread and is part of the release notes for the last 3 releases of RRO; however, it might not be easy to find the answer.

Have a good day,
Josée

@aaronthor
Copy link

Hello Josée and Stephen,

Yeah, I've missed it somehow. Got it working now. Appreciate your guidance fellas!
Have a wonderful weekend ahead!

Cheers,
Aaron

@tshtatland
Copy link

Thank you for documenting the workaround. I am adding:

Known Issues

  • devtools::install_bitbucket() may fail with the error "error in running command" on Ubuntu. To work around this issue, set options(unzip = 'internal') before calling install_bitbucket.

Example:

> library(devtools)
> install_bitbucket("repo_name")
Downloading bitbucket repo repo_name
Installation failed: error in running command
> sessionInfo()
R version 3.3.2 (2016-10-31)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 16.04.2 LTS

locale:
[1] C

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] devtools_1.13.2

loaded via a namespace (and not attached):
[1] httr_1.2.1    R6_2.2.2      withr_1.0.2   curl_2.8.1    memoise_1.1.0
[6] git2r_0.19.0  digest_0.6.12

@seonghobae
Copy link

another solution in ubuntu 16.04: run apt install unzip

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests