package xlsx error

When I try to load package "xlsx" in RStudio it crashes with "R session aborted, R encountered a fatal error".
I am running:
Windows 10 21H2
RStudio 2022.02.2 Build 485
R 4.2.0
xlsx package 0.6.5

I am starting RStudio with a clean environment, and when I try library(xlsx) in R it works fine. library(rJava) also works in RStudio.
Any ideas where I should start looking for the error?

/Thomas Bendsen

I get this too. I couldn't figure out what it was cause I load all packages with pacman. I had to take packages out of the statement to figure out what it was. and it only does it with R 4.2 in RStudio. It won't do it in PowerShell 7.2

I've found a description of the underlying problem here:

In the bottom there is a link to a patched version of R 4.2.0, that does indeed solve the problem.
/Thomas

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.