Help with the error please..

When I was trying to install tidyvers, it shows like this:

install.packages("tidyverse")
also installing the dependency ‘jsonlite’

There is a binary version available but the source version is later:
binary source needs_compilation
jsonlite 1.8.0 1.8.1 TRUE

Do you want to install from sources the package which needs compilation? (Yes/no/cancel) yes
trying URL 'https://cran.rstudio.com/bin/macosx/contrib/4.2/tidyverse_1.3.2.tgz'
Content type 'application/x-gzip' length 420896 bytes (411 KB)

downloaded 411 KB

The downloaded binary packages are in
/var/folders/wl/5c5p8ck56211fcnpd4hgrvrm0000gn/T//RtmplphGmK/downloaded_packages
installing the source package ‘jsonlite’

trying URL 'https://cran.rstudio.com/src/contrib/jsonlite_1.8.1.tar.gz'
Content type 'application/x-gzip' length 1053086 bytes (1.0 MB)

downloaded 1.0 MB

  • installing source package ‘jsonlite’ ...
    ** package ‘jsonlite’ successfully unpacked and MD5 sums checked
    ** using staged installation
    ** libs
    xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
    ERROR: compilation failed for package ‘jsonlite’
  • removing ‘/Library/Frameworks/R.framework/Versions/4.2/Resources/library/jsonlite’
    Warning in install.packages :
    installation of package ‘jsonlite’ had non-zero exit status

The downloaded source packages are in
‘/private/var/folders/wl/5c5p8ck56211fcnpd4hgrvrm0000gn/T/RtmplphGmK/downloaded_packages’

library(tidyverse)
Error: package or namespace load failed for ‘tidyverse’ in loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]]):
there is no package called ‘vctrs’

How should I solve this problem...
Thank you so much!!!!!

The easiest solution would be to answer "no" to this question, you would get a precompiled binary version that is a little older but much easier to install.
If you need to install the latest version from source, then you need to install Xcode in your system (not in R) and the recommended development tools for macOS systems.
https://mac.r-project.org/tools/

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

If you have a query related to it or one of the replies, start a new topic and refer back with a link.