New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ggplot2 crashes RStudio after upgrading to R 4.1.0 #9373
Comments
I am experiencing this exact same problem. I have tried the following (without success):
|
I have the same problem here as well. Same OS, same R and Studio version. Downgrading to r-4.0.5-4 solved the issue, but this obviously can't be a long term solution. Cheers |
Of course! I'm not sure why I overlooked doing that - thank you for the suggestion. I have the downgrade (9.0.0-1) utility found on AUR, however, running How did you downgrade R? |
Very simple, just go to your package cache directory in: /var/cache/pacman/pkg/ |
Hi. I can confirm the issue in the same environment as the OP. sudo aptitude install r-base=4.0.5-1.2004.0 r-recommended=4.0.5-1.2004.0 r-base-core=4.0.5-1.2004.0 r-base-dev=4.0.5-1.2004.0 |
Thank you for the explanation, and the wiki link. It worked, but you're right - this is not a long ter solution. |
@PMassicotte Thank you for filing the issue, and everyone for the added information! We don't support Linux Mint or Arch Linux. However, I can reproduce the issue on Ubuntu 20.04. Support for R 4.1.0 is provided in the upcoming Juliet Rose release, so thank you for confirming that it works in the dailies. We now have a preview available at https://www.rstudio.com/products/rstudio/download/preview/ . Caveat: previews are still meant for testing purposes only, but they're fairly stable. |
Thank you, @ronblum , I can confirm that the preview version is working. |
@PMassicotte Excellent, I appreciate your test and confirmation! |
For future searches, the error is: ERROR elf_dynamic_array_reader.h:61] tag not found |
I can also confirm that the preview fixes the issue on CentOS 8. |
Downgrading to R 4.05 worked on Ubuntu 20.04 (I was afraid to try the preview as 20.04 wasn't listed only 18.04)
|
Hello! I have the same problem, as advised downgrading to R 4.05 worked fine on Linux Mint 20. |
Just to jump in, I noticed this is an issue with the grid::grid.newpage() I can confirm that using the preview version "Juliet Rose" (e7ab0fe, 2021-05-20) RStudio no longer crashes. Session infoR version 4.1.0 (2021-05-18)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 18.04.5 LTS
Matrix products: default
BLAS: /usr/lib/x86_64-linux-gnu/atlas/libblas.so.3.10.3
LAPACK: /usr/lib/x86_64-linux-gnu/atlas/liblapack.so.3.10.3
locale:
[1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C LC_TIME=en_US.UTF-8 LC_COLLATE=en_US.UTF-8
[5] LC_MONETARY=en_US.UTF-8 LC_MESSAGES=en_US.UTF-8 LC_PAPER=en_US.UTF-8 LC_NAME=C
[9] LC_ADDRESS=C LC_TELEPHONE=C LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C
attached base packages:
[1] stats graphics grDevices utils datasets methods base
loaded via a namespace (and not attached):
[1] compiler_4.1.0 tools_4.1.0 RStudio version 1.4.1106 cc @ronblum |
@gvegayon Which OS and version of RStudio does this occur in? Is this still a problem in the current 1.4. Juliet Rose preview? [Note: I can reproduce the problem on Red Hat 7 in RStudio Server 1.4.1106, and everything works fine in 1.4.1714 preview.] |
To confirm, the issue does effect all packages using |
Also, although you probably know already, I believe the issue only manifests itself when calling |
I can confirm this problem. Here's my session info: R version 4.1.0 (2021-05-18)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 20.04.2 LTS
Matrix products: default
BLAS: /usr/lib/x86_64-linux-gnu/blas/libblas.so.3.9.0
LAPACK: /usr/lib/x86_64-linux-gnu/lapack/liblapack.so.3.9.0
locale:
[1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C
[3] LC_TIME=es_MX.UTF-8 LC_COLLATE=en_US.UTF-8
[5] LC_MONETARY=es_MX.UTF-8 LC_MESSAGES=en_US.UTF-8
[7] LC_PAPER=es_MX.UTF-8 LC_NAME=C
[9] LC_ADDRESS=C LC_TELEPHONE=C
[11] LC_MEASUREMENT=es_MX.UTF-8 LC_IDENTIFICATION=C
attached base packages:
[1] stats graphics grDevices utils datasets methods base
loaded via a namespace (and not attached):
[1] compiler_4.1.0 I had to switch to VS Code (I noticed that using VS Code or the R terminal, the R session doesn't crash). Can't downgrade in our work servers, since our company's security policy doesn't allow it. |
@pablorm296: is installing the preview release of RStudio an option? It contains a fix for this issue. |
If for any reason you can't downgrade R or install preview version of Rstudio, a possible temporary work around is to output the graph to another device, such as a .pdf file. |
I also encountered the same problem on my Ubuntu machine, but thanks to the people above I was able to solve the issue after installing the preview version |
Another "solution" is using the x11() command before ggplot() command, like that: |
This is a much better solution than dropping down to a previous rstudio version, since we're just waiting on a preview release to be approved. |
The preview release has now been officially approved (we just don't want to release it before the long weekend in the US). It will become the stable/official build next week, but the bits won't change. 1.4.1717-3 is the final build: https://www.rstudio.com/products/rstudio/download/preview/ |
@jmcphers great to hear about this! Confirming also the bug affecting the Server version when running on Ubuntu 18.04, and being fixed in the preview! |
Issue solved with the 1.4.1717-3 preview in Ubuntu 18.04.5 LTS |
@MatthieuStigler and @mabba777 Thank you for letting us know! |
As a hotfix, switching to the AGG backend in Here's an updated PKGBUILD for the fixed version (not updated in AUR yet). I just changed the version number and the SHA256 hash of the DEB file and it seems to work. |
In case it's of use/interest I've seen a few crashes with
|
@Robinlovelace: if you can, please file a new issue with more details + a reproducible example (even if the example only reproduces occasionally) |
Hi @kevinushey, it was very intermittent, something like 1 in 5 to 10 plots causing crashing. I recall seeing something along the lines of
multiple times behind the 💣 of the RStudio crash. Following info in this thread I've now switched to using |
Not that I'm planning to do that, lots of things on, just commented under this issue after it chimed with my experience and wondering if one of the proposed solutions would work for my case. |
Apologies for another update but that version has just crashed with another tmap plot, not in interactive mode. |
A reproducible example (something I could copy and paste to try and reproduce) would be helpful. |
I can provide a reprex, will send an invite to the repo I'm working on now... It involves a bit of data crunching but is reproducible. |
(Unfortunately I cannot share the code publicly atm.) |
Hello, I seem to be having this issue as well. Currently after some debugging I have found that calling Specifically at a line in the I have confirmed that if I run R through command line, For some additional context I updated the R version to 4.1.2 in December of 2021. ---- EDIT ---- After updating to |
Hello,
It happens anytime I run this code:
Or latest, when I try plotting the graph thereafter. I tried some of the suggested solutions like x11() and switching to AGG backend, but they do not work. I update all packages, too. I would really appreciate any help to solves this, as I urgendtly need to create some graphs for work. Thank you so much and of course I will provide any info that might be helpful. |
This is happening for me on M1 OSX 13.3 using R 4.2.3.
|
System details
Steps to reproduce the problem
Since I upgraded to R 4.1.0, RStudio crashes when I try to create a ggplot2 graph.
Describe the problem in detail
diagnostics-report.txt
The text was updated successfully, but these errors were encountered: