RStudio v1.1.423 crashes - "Unable to establish connection with R session"

I am a university student using R Studio desktop edition (the free edition). I'm running my code and it appears that the notification of Unable to establish connection with R session comes up quite often and truncates all the work that I have been doing. Is there an issue with R Studio or something I would greatly appreciate some help.
I am running R Studio on macOS High Sierra version 10.13.4.

59%20PM

Does this happen while you are running a script that is taking time to
finish? Or even while the > prompt is visible on the console?

This happens while I am running a script that is taking time to finish and when I am creating plots. Sometimes, I do see the "Unable to establish connection with R session" on the console.

That happens for me too usually if R is accessing a database. Rstudio cannot connect with R session which is busy executing the thread. Killing of R session is a problem in Rstudio.

Let's see what others have to say.

Sanjay