natverse / nat

NeuroAnatomy Toolbox: An R package for the (3D) visualisation and analysis of biological image data, especially tracings of single neurons.
https://natverse.org/nat/
64 stars 29 forks source link

issues installing nat #408

Closed dpacheco0921 closed 5 years ago

dpacheco0921 commented 5 years ago

I tried installing NAT and dependencies: install.packages("nat", dependencies=TRUE) This works fine.

However: if (!require("devtools")) install.packages("devtools") give me this error: Loading required package: devtools Loading required package: usethis Error: package or namespace load failed for ‘usethis’ in loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]]): there is no package called ‘Rcpp’ Failed with error: ‘package ‘usethis’ could not be loaded’

Although at the end it also says: package ‘devtools’ successfully unpacked and MD5 sums checked

Then when I do: devtools::install_github("natverse/nat") I get the folloring error: Error in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]) : there is no package called ‘rlang’

I am using R version 3.6.0 (2019-04-26) on windows

jefferis commented 5 years ago

For interest, can you just try:

if (!require("remotes")) install.packages("remotes")
remotes::install_github('natverse/nat')

Anyway, this seems to be some devtools issue. Google will probably get you somewhere. If you

install.packages("rlang")
install.packages("Rcpp")

I'm fairly sure you will be up and running again. As usual restart R before package installs.

dpacheco0921 commented 5 years ago

Thanks! However, after installing rlang and rcpp. I run:

if (!require("remotes")) install.packages("remotes") remotes::install_github('natverse/nat')

or

if (!require("devtools")) install.packages("devtools") devtools::install_github("natverse/nat")

I got this error:

Execution halted ERROR: lazy loading failed for package 'nat' * removing 'C:/Users/Diego/Documents/R/win-library/3.6/nat' * restoring previous 'C:/Users/Diego/Documents/R/win-library/3.6/nat' Error: Failed to install 'nat' from GitHub: (converted from warning) installation of package ‘C:/Users/Diego/AppData/Local/Temp/Rtmpo5YclU/file208453ac12f8/nat_1.9.1.9000.tar.gz’ had non-zero exit status

jefferis commented 5 years ago

Did you start a new R session? Can you paste the result of devtools::session_info() maybe before and after trying the install.

jefferis commented 5 years ago

Also the error message you reported in your last message looks incomplete. Can you copy the full output when you do devtools::install_github?

dpacheco0921 commented 5 years ago

I did, but it did not fix the problem. However I updated R from R 3.6.0 to R 3.6.1, and this fixed it!

Side question, to install other related packages (flybrains, templatebrains, elmr, etc), should I do them independently:

devtools::install_github("jefferislab/nat.flybrains")
devtools::install_github("jefferislab/nat.templatebrains")

and so on ...

or should I use:

devtools::install_github("SridharJagannathan/natverse")
jefferis commented 5 years ago

Hmm ok. I think your package library had some kind of inconsistency. It’s possible that upgrading installed packages rather than upgrading R might also have fixed if. Anyway glad you were able to fix.

Re your question, we are in the midst of a major reorganisation of the hosting/docs/distribution of all nat related packages. You should be able to do

devtools::install_github("natverse/natverse”)

Let us know how you get on.

Best,

Greg.

Sent from my iPhone

On 5 Aug 2019, at 22:17, Diego A Pacheco Pinedo notifications@github.com wrote:

I did, but it did not fix the problem. However I updated R from R 3.6.0 to R 3.6.1, and this fixed it!

Side question, to install other related packages (flybrains, templatebrains, elmr, etc), should I do them independently:

devtools::install_github("jefferislab/nat.flybrains") devtools::install_github("jefferislab/nat.templatebrains") and so on ...

or should I use:

devtools::install_github("SridharJagannathan/natverse") — You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.

jefferis commented 5 years ago

One other hypothesis relating to a windows install issue: https://stackoverflow.com/questions/56888506/problems-installing-packages-devtools-and-callr-on-windows.

In any case I’m fairly confident that this was a general issue and not anything specifically to do with nat, so I’m closing the issue.