namespace error

Hey guys,

I have this error since updating my R Studio to newest version:

if i want to load in the package tidyverse, this message is coming:

library(tidyverse)
Error: package or namespace load failed for ‘tidyverse’ in loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]]):
es gibt kein Paket namens ‘lifecycle’

sessionInfo()
R version 4.0.5 (2021-03-31)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 22000)

Matrix products: default

locale:
[1] LC_COLLATE=German_Germany.1252 LC_CTYPE=German_Germany.1252 LC_MONETARY=German_Germany.1252 LC_NUMERIC=C
[5] LC_TIME=German_Germany.1252

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

loaded via a namespace (and not attached):
[1] compiler_4.0.5 R6_2.5.0 generics_0.1.0 cli_3.2.0 tools_4.0.5 glue_1.4.2 vctrs_0.4.1 rlang_1.0.2

Do you have an idea to fix this?

Thanks in advance!

R has failed to load a needed dependency package that **tidyverse ** needs. Try

install.packages("lifecycle")
install.packages("tidyverse")

Repeat if you get another similar error message.

tried that too but these are the results:

install.packages("lifecycle")
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/zappe/Documents/R/win-library/4.0’
(as ‘lib’ is unspecified)
also installing the dependencies ‘cli’, ‘rlang’

There are binary versions available but the source versions are later:
binary source needs_compilation
cli 3.2.0 3.4.1 TRUE
rlang 1.0.2 1.0.6 TRUE
lifecycle 1.0.1 1.0.3 FALSE

Binaries will be installed
trying URL 'ht*tps://cran.rstudio.com/bin/windows/contrib/4.0/cli_3.2.0.zip'
Content type 'application/zip' length 1255499 bytes (1.2 MB)
downloaded 1.2 MB

trying URL 'ht*tps://cran.rstudio.com/bin/windows/contrib/4.0/rlang_1.0.2.zip'
Content type 'application/zip' length 1718546 bytes (1.6 MB)
downloaded 1.6 MB

package ‘cli’ successfully unpacked and MD5 sums checked
Warning in install.packages :
cannot remove prior installation of package ‘cli’
package ‘rlang’ successfully unpacked and MD5 sums checked
Warning in install.packages :
cannot remove prior installation of package ‘rlang’

The downloaded binary packages are in
C:\Users\zappe\AppData\Local\Temp\RtmpyW87PO\downloaded_packages
installing the source package ‘lifecycle’

trying URL 'http*s://cran.rstudio.com/src/contrib/lifecycle_1.0.3.tar.gz'
Content type 'application/x-gzip' length 106854 bytes (104 KB)
downloaded 104 KB

ERROR: dependencies 'cli', 'rlang' are not available for package 'lifecycle'

  • removing 'C:/Users/zappe/Documents/R/win-library/4.0/lifecycle'
    Warning in install.packages :
    installation of package ‘lifecycle’ had non-zero exit status

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

install.packages(tidyverse)
Error in install.packages : object 'tidyverse' not found
Namensraum ‘lifecycle’ 1.0.0 ist geladen, aber >= 1.0.1 wird benötigt

needed to do the ""symbal bc of hyperlik restriction*

I don't remember running into this before but it looks like you will have to manually remove those packages.

See
Fixing the Warning Message: cannot remove prior installation of package ‘X’

What is your operating system?

Hi @germanguy install Rtools, and next lifecycle and tidyverse.

Ah, you are right. I misread the error message and thought he had Rtools installed. My bad.

You are using a fairly old R version so there are no precompiled binaries for the latest package versions available for it, you can either install RTools40 in your system so you can compile packages from source or update your R version so you can get access to precompiled binaries.

Thank you, I unistalled my version of R, installed the newest version, installed Rtools, retried and it worked.

This topic was automatically closed 7 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.