Hi All, new user on the RStudio community but have been a long-time user of the program.
Starting a few days ago, I have been getting this issue that has been driving me absolutely crazy with the Rstudio console. I have no idea why it is happening, and the only way I've been able to 'fix' it is by ctrl+alt+del and then restarting.
Basically, I will work in RStudio and at some point the console seems to get stuck. As in, the cursor disappears and nothing I input into the console will go through. I can no longer save scripts, click through menu options, or even exit the program by x'ing out of the top right button.
It's like the console is stuck in a loop, but I have no loop in the current script I'm writing. There also no stop sign in the top right of the console to signify it's running logic. Task manager shows it's eating about about 25% of my cpu which seems high but it's not like its topping out or anything.
The timing of this seems completely random. Sometimes I can work on this script for an hour, sometimes for 5 minutes.
It seems like an internet connection could be involved. When I disconnect my ethernet cord I immediately get an "Error: Unable to establish connection with R session" error. This resets the console cursor, but as soon as I type another command the problem immediately reappears. Here's a screenshot to give an idea of what's happening.
As a background. I have the most recent version of R and RStudio. I've also tried this with the lastest RStudio preview and get the same issue. I've tried across two computers and the issue arises with both.
What would account for this type of behavior? I've been using R on and off for the better part of a decade and never had this issue before.
After some more testing, this is almost certainly a problem with windows defender firewall. I didn't think this was the case originally as I had allowed R and RStudio to communicate through Windows Defender Firewall and was still having the issue.
However, I turned off my firewall completely last night and the issue hasn't reappeared since (about 5 hours work time). So certainly that's the case.
Long-term though, it's probably not a good idea to completely turn off my firewall. Is there something beyond RStudio and R that needs to be added to the exception list? I've also added 'Qt Qtwebengineprocess' and 'RStudio R Session' to the exception list but continued to have the same issue.
Running Version 1.2.5033 (desktop). Diagnostic report below.
As an update, this problem continues to persist. I humbly ask if anyone has the ability to help to do so.
Turning off windows defender has lessened the issue, but it still occurs. After further trouble shooting, it might have something to do with tab-completion. It seems to always happen when I am writing and there is a tab-complete box. It never occurs when I am actually executing code (i.e. not writing anything).
I would greatly appreciate any advice into this ongoing bug.
Should be the final update on this. I've found the root of the problem and wanted to self-answer for any poor sacks who might get into the same situation as me.
I have a script that is sourced at the beginning of all my work with libraries to load in. About 2 weeks ago I added Rfast for a single function and it appears it doesn't work with dplyr.
After realizing RStudio froze everytime I was writing, and specifically everytime I was using a dplyr function, I tried loading ONLY dplyr and sure enough the problem went away. At that point it was just a matter of loading packages from my list and testing a dplyr function until RStudio froze. Package Rfast was the culprit and as long as I don't load that I have zero issues.
I know this isn't an RStudio problem, but wanted to give an answer regardless for anyone else having that problem. I've never had packages break each other before, so it was a very unique situation for me. If there's another place anyone recommends to pass this problem along, I'd be happy to help the community in any way.