error is installing tidyverse

install.packages("tidyverse")
WARNING: Rtools is required to build R packages but is not currently installed. Please download and install the appropriate version of Rtools before proceeding:

https://cran.rstudio.com/bin/windows/Rtools/
Installing package into ‘C:/Users/Zeeshan/OneDrive/Documents/R/win-library/3.6’
(as ‘lib’ is unspecified)
also installing the dependencies ‘rlang’, ‘tibble’, ‘broom’

There are binary versions available but the source versions are later:
binary source needs_compilation
rlang 0.4.6 0.4.7 TRUE
broom 0.5.6 0.7.0 FALSE

Binaries will be installed
trying URL 'https://cran.rstudio.com/bin/windows/contrib/3.6/rlang_0.4.6.zip'
Content type 'application/zip' length 1129926 bytes (1.1 MB)
downloaded 1.1 MB

trying URL 'https://cran.rstudio.com/bin/windows/contrib/3.6/tibble_3.0.2.zip'
Content type 'application/zip' length 414560 bytes (404 KB)
downloaded 404 KB

trying URL 'https://cran.rstudio.com/bin/windows/contrib/3.6/tidyverse_1.3.0.zip'
Content type 'application/zip' length 440119 bytes (429 KB)
downloaded 429 KB

package ‘rlang’ successfully unpacked and MD5 sums checked
Warning in install.packages :
cannot remove prior installation of package ‘rlang’
Warning in install.packages :
problem copying C:\Users\Zeeshan\OneDrive\Documents\R\win-library\3.6\00LOCK\rlang\libs\x64\rlang.dll to C:\Users\Zeeshan\OneDrive\Documents\R\win-library\3.6\rlang\libs\x64\rlang.dll: Permission denied
Warning in install.packages :
restored ‘rlang’
package ‘tibble’ successfully unpacked and MD5 sums checked
Warning in install.packages :
cannot remove prior installation of package ‘tibble’
Warning in install.packages :
problem copying C:\Users\Zeeshan\OneDrive\Documents\R\win-library\3.6\00LOCK\tibble\libs\x64\tibble.dll to C:\Users\Zeeshan\OneDrive\Documents\R\win-library\3.6\tibble\libs\x64\tibble.dll: Permission denied
Warning in install.packages :
restored ‘tibble’
package ‘tidyverse’ successfully unpacked and MD5 sums checked

The downloaded binary packages are in
C:\Users\Zeeshan\AppData\Local\Temp\RtmpM74KMy\downloaded_packages
installing the source package ‘broom’

trying URL 'https://cran.rstudio.com/src/contrib/broom_0.7.0.tar.gz'
Content type 'application/x-gzip' length 604195 bytes (590 KB)
downloaded 590 KB

  • installing source package 'broom' ...
    ** package 'broom' successfully unpacked and MD5 sums checked
    ** using staged installation
    ** R
    ** inst
    ** byte-compile and prepare package for lazy loading
    Error in loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]]) :
    namespace 'tibble' 2.1.3 is already loaded, but >= 3.0.0 is required
    Calls: ... namespaceImportFrom -> asNamespace -> loadNamespace
    Execution halted
    ERROR: lazy loading failed for package 'broom'
  • removing 'C:/Users/Zeeshan/OneDrive/Documents/R/win-library/3.6/broom'
    Warning in install.packages :
    installation of package ‘broom’ had non-zero exit status

The downloaded source packages are in
‘C:\Users\Zeeshan\AppData\Local\Temp\RtmpM74KMy\downloaded_packages’

Do you have several sessions of Rstudio open? Did you try to restart R? That did solve a similar problem for me previously.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.