Installing packages tidyverse

Hi there,

I am very new to using Jupyter and I am struggling to install the tidyverse package.

I keep getting the below error, any help would be greatly appreciated.

Thanks

You aren’t showing the end of cell 1 in your post. Cell #2 doesn’t work because cell #1 was most likely not successful?

Also, it is never a good idea to just show an image in a post, especially if it involves code and an error. (Or possibly an error. In this case, the inadequacy of an image alone is apparent: I’m concerned with the end of cell#1 but I cannot examine it from a static image.) In your case as the tidyverse includes a lot, you may want to truncate or place the entire output/error snippet elsewhere, but we’d at least like to have the text you ran, the text at the beginning and towards end of cell #1 to offer assistance. Part of the reason for including code as text and not just an image is that you want to help those helping you. Granted in this case, your “code” is only a couple lines, it makes it easier for those trying to help you if they can just copy-paste.

1 Like

Thanks for taking the time to get back to me, here is the full code -

also installing the dependencies ‘processx’, ‘xfun’, ‘bslib’, ‘htmltools’, ‘tinytex’, ‘lifecycle’, ‘tidyselect’, ‘vctrs’, ‘scales’, ‘gargle’, ‘timechange’, ‘vroom’, ‘callr’, ‘knitr’, ‘rmarkdown’, ‘broom’, ‘cli’, ‘dbplyr’, ‘dplyr’, ‘dtplyr’, ‘forcats’, ‘ggplot2’, ‘googledrive’, ‘googlesheets4’, ‘haven’, ‘hms’, ‘jsonlite’, ‘lubridate’, ‘modelr’, ‘pillar’, ‘readr’, ‘reprex’, ‘rlang’, ‘rvest’, ‘tibble’, ‘tidyr’, ‘xml2’

There are binary versions available but the source versions are later:
binary source needs_compilation
processx 3.5.2 3.8.0 TRUE
xfun 0.22 0.34 TRUE
bslib 0.2.4 0.4.1 FALSE
htmltools 0.5.1.1 0.5.3 TRUE
tinytex 0.31 0.42 FALSE
lifecycle 1.0.0 1.0.3 FALSE
tidyselect 1.1.1 1.2.0 FALSE
vctrs 0.3.8 0.5.0 TRUE
scales 1.1.1 1.2.1 FALSE
gargle 1.1.0 1.2.1 FALSE
timechange 0.0.2 0.1.1 TRUE
vroom 1.4.0 1.6.0 TRUE
callr 3.7.0 3.7.3 FALSE
knitr 1.33 1.40 FALSE
rmarkdown 2.8 2.18 FALSE
broom 0.7.6 1.0.1 FALSE
cli 2.5.0 3.4.1 TRUE
dbplyr 2.1.1 2.2.1 FALSE
dplyr 1.0.6 1.0.10 TRUE
dtplyr 1.1.0 1.2.2 FALSE
forcats 0.5.1 0.5.2 FALSE
ggplot2 3.3.3 3.4.0 FALSE
googledrive 1.0.1 2.0.0 FALSE
googlesheets4 0.3.0 1.0.1 FALSE
haven 2.4.1 2.5.1 TRUE
hms 1.0.0 1.1.2 FALSE
jsonlite 1.7.2 1.8.3 TRUE
lubridate 1.7.10 1.9.0 TRUE
modelr 0.1.8 0.1.9 FALSE
pillar 1.6.0 1.8.1 FALSE
readr 1.4.0 2.1.3 TRUE
reprex 2.0.0 2.0.2 FALSE
rlang 0.4.11 1.0.6 TRUE
rvest 1.0.0 1.0.3 FALSE
tibble 3.1.1 3.1.8 TRUE
tidyr 1.1.3 1.2.1 TRUE
xml2 1.3.2 1.3.3 TRUE
tidyverse 1.3.1 1.3.2 FALSE

Binaries will be installed
package ‘processx’ successfully unpacked and MD5 sums checked
package ‘xfun’ successfully unpacked and MD5 sums checked
package ‘htmltools’ successfully unpacked and MD5 sums checked
Warning message:
"cannot remove prior installation of package ‘htmltools’"Warning message in file.copy(savedcopy, lib, recursive = TRUE):
"problem copying C:\Users\Bakes\miniconda3\Lib\R\library\00LOCK\htmltools\libs\x64\htmltools.dll to C:\Users\Bakes\miniconda3\Lib\R\library\htmltools\libs\x64\htmltools.dll: Permission denied"Warning message:
“restored ‘htmltools’”
package ‘vctrs’ successfully unpacked and MD5 sums checked
package ‘timechange’ successfully unpacked and MD5 sums checked
package ‘vroom’ successfully unpacked and MD5 sums checked
package ‘cli’ successfully unpacked and MD5 sums checked
package ‘dplyr’ successfully unpacked and MD5 sums checked
package ‘haven’ successfully unpacked and MD5 sums checked
package ‘jsonlite’ successfully unpacked and MD5 sums checked
Warning message:
"cannot remove prior installation of package ‘jsonlite’"Warning message in file.copy(savedcopy, lib, recursive = TRUE):
"problem copying C:\Users\Bakes\miniconda3\Lib\R\library\00LOCK\jsonlite\libs\x64\jsonlite.dll to C:\Users\Bakes\miniconda3\Lib\R\library\jsonlite\libs\x64\jsonlite.dll: Permission denied"Warning message:
“restored ‘jsonlite’”
package ‘lubridate’ successfully unpacked and MD5 sums checked
package ‘readr’ successfully unpacked and MD5 sums checked
package ‘rlang’ successfully unpacked and MD5 sums checked
package ‘tibble’ successfully unpacked and MD5 sums checked
package ‘tidyr’ successfully unpacked and MD5 sums checked
package ‘xml2’ successfully unpacked and MD5 sums checked

The downloaded binary packages are in
C:\Users\Bakes\AppData\Local\Temp\RtmpQ9XGRw\downloaded_packages
installing the source packages ‘bslib’, ‘tinytex’, ‘lifecycle’, ‘tidyselect’, ‘scales’, ‘gargle’, ‘callr’, ‘knitr’, ‘rmarkdown’, ‘broom’, ‘dbplyr’, ‘dtplyr’, ‘forcats’, ‘ggplot2’, ‘googledrive’, ‘googlesheets4’, ‘hms’, ‘modelr’, ‘pillar’, ‘reprex’, ‘rvest’, ‘tidyverse’

Warning message in install.packages(“tidyverse”):
"installation of package ‘bslib’ had non-zero exit status"Warning message in install.packages(“tidyverse”):
"installation of package ‘tinytex’ had non-zero exit status"Warning message in install.packages(“tidyverse”):
"installation of package ‘lifecycle’ had non-zero exit status"Warning message in install.packages(“tidyverse”):
"installation of package ‘gargle’ had non-zero exit status"Warning message in install.packages(“tidyverse”):
“installation of package ‘callr’ had non-zero exit status”

A few things:

After it fails, most people seem to suggest removing everything it tried to install and then trying again. So I recommend first running:

remove.packages("tidyverse")

Did you try install.packages('tidyverse', type = 'binary')? (It was suggested in discussion below and here.) Here suggested also including dependencies = TRUE in the install command.

Also, be careful to not leave R running elsewhere on you machine ever when you try upgrading. Here it says," On Windows, R can do a nasty thing if you try to upgrade a package that’s currently in use: it can partially succeed and partially fail and leave you in a broken state."

More detailed discussion that I’ve found that seems similar to what you are seeing is this post. It has some suggestions such as just installing some of the packages that you plan to use individually, such as dplyr , ggplot2 , tidyr.

Is your R version relatively new, but not the most bleeding edge? Getting a recent version was the solution to Non-zero exit status tidyverse install packages Rstudio.

Thanks

I followed your advice and got it to work :slight_smile:

Thank you again for your help.

1 Like