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

System command 'R' failed for any packages #720

Closed
Zepeng-Mu opened this issue Sep 2, 2022 · 3 comments
Closed

System command 'R' failed for any packages #720

Zepeng-Mu opened this issue Sep 2, 2022 · 3 comments

Comments

@Zepeng-Mu
Copy link

> remotes::install_github("stephenslab/mashr", build_vignettes = F)
Downloading GitHub repo stephenslab/mashr@HEADchecking for file/tmp/Rtmp04xv01/remotes57651587d912/stephenslab-mashr-e482cf2/DESCRIPTION’ (362ms)
─  preparingmashr:checking DESCRIPTION meta-information ...cleaning srcrunningcleanup’
─  checking for LF line-endings in source and make files and shell scripts
   Warning in file(file, "wb") :
     cannot open file 'mashr/cleanup': Text file busy
   Error in file(file, "wb") : cannot open the connection
   Execution halted
Error: Failed to install 'mashr' from GitHub:
  ! System command 'R' failed

I get this "System command 'R' failed" error message when using devtools::install_github() or remotes::install_github(). This is happening to all packages. I'm using a conda env.

> sessionInfo()
R version 4.0.5 (2021-03-31)
Platform: x86_64-conda-linux-gnu (64-bit)
Running under: Scientific Linux 7.4 (Nitrogen)

Matrix products: default
BLAS/LAPACK: /scratch/midway2/zepengmu/conda_envs/newbase/lib/libopenblasp-r0.3.18.so

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C
 [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8
 [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8
 [7] LC_PAPER=en_US.UTF-8       LC_NAME=C
 [9] LC_ADDRESS=C               LC_TELEPHONE=C
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C

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

loaded via a namespace (and not attached):
 [1] processx_3.6.1    compiler_4.0.5    R6_2.5.1          rprojroot_2.0.3
 [5] cli_3.3.0         prettyunits_1.1.1 tools_4.0.5       withr_2.5.0
 [9] curl_4.3.2        crayon_1.5.1      remotes_2.4.2     callr_3.7.0
[13] ps_1.7.1          pkgbuild_1.3.1
@gaborcsardi
Copy link
Member

Try standalone mode, see https://github.com/r-lib/remotes#standalone-mode

Did you install R from conda? If not then deactivate conda while using R.

@Zepeng-Mu
Copy link
Author

Thanks for the quick reply. I actually also need set build=F. I'm not sure what it means. My R is installed with conda. It worked fine before, but I recently updated conda.

> Sys.setenv(R_REMOTES_STANDALONE="true")
> remotes::install_github("stephenslab/mashr")
Downloading GitHub repo stephenslab/mashr@HEAD
Running `R CMD build`...
* checking for file/tmp/RtmpYeymKC/remotes7ade6369c45/stephenslab-mashr-e482cf2/DESCRIPTION... OK
* preparingmashr:
* checking DESCRIPTION meta-information ... OK
* cleaning src
* runningcleanup* checking for LF line-endings in source and make files and shell scripts
STDOUT:
* checking for file/tmp/RtmpYeymKC/remotes7ade6369c45/stephenslab-mashr-e482cf2/DESCRIPTION... OK
* preparingmashr:
* checking DESCRIPTION meta-information ... OK
* cleaning src
* runningcleanup* checking for LF line-endings in source and make files and shell scripts
STDERR:
Warning in file(file, "wb") :
  cannot open file 'mashr/cleanup': Text file busy
Error in file(file, "wb") : cannot open the connection
Execution halted
Error: Failed to install 'mashr' from GitHub:
  Failed to `R CMD build` package, try `build = FALSE`.
> remotes::install_github("stephenslab/mashr", build=F)

@gaborcsardi
Copy link
Member

Unfortunately it is unlikely that we can help you with this, because we don't use conda.

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