ggplotly function on ggplot2 object crashes R & RStudio

A simple call of ggplotly() on a ggplot2 object makes RStudio Crash. The simple code is started below.

library(plotly)
library(tidyverse)

iris.ggplot <- ggplot(data = iris, aes(x = Sepal.Length, y = Sepal.Width, color = Species)) +
  geom_point()

print(iris.ggplot)

ggplotly(iris.ggplot)

That code runs normally for me with Rstudio Server 1.2.1252, R 3.5.2, Ubuntu Server 16.04 LTS
What is your setup?

I am using Fedora 29 OS. I have really searched hard on the internet to find a solution, however, couldn't find any solution.

What R and Rstudio versions are you using? Also, have you updated your packages? (i.e. ggplot2, plotly)

Following are the details. Also I have updated the packages, but still to no affect.

R Version - R version 3.5.1 (2018-07-02)
RStudio Version - Version 1.2.1114

Dear andresrcs,

I believe to some extent I have narrowed down the resolution, however, I am not able to resolve the issue. The problem also happens when library(shiny) is used.

http://shiny.rstudio.com/articles/upgrade-R.html

Have you recently updated to R 3.5.1 from R <= 3.4.X? If you have installed precompiled libraries with apt from system console under R <= 3.4.X, try removing those with sudo apt remove -y 'r-cran-*' and reinstalling with the new version of R, also, make sure that all your other libraries are up to date update.packages(checkBuilt=TRUE, ask=FALSE)

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