Hi everyone!
I just updated R and RStudio Desktop to the latest version on Ubuntu and I messed up something.
I can open the latest R version but when I open RStudio the startup fails...
I managed to copy the diagnostics (see below). Can anyone understand what's going on?
R Session Startup Failure Report
RStudio Version
RStudio 2022.07.2+576, "Spotted Wakerobin" (e7373ef8, 2022-09-06) for Ubuntu Jammy
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) QtWebEngine/5.12.8 Chrome/69.0.3497.128 Safari/537.36
The 'PATHis the order in which commands are loaded, andSHELL` is the type of command line settings that determines the search order. What does yours show?
i do not have a .RProfile file in HOME directory.
so, I created one with "touch" and added the code you sent but nothing changed.
is there anything else i can try before backing up my files and reinstalling ubuntu from scratch?
RStudio is already in the path regardless of the position and it is trying to load (with an error) so there is no point in going that way. Also, make sure to also remove the custom .Rprofile you have added to avoid possible conflicts. (there should not be a need for one to start a clean install of R).
You said R is working so I wouldn't go that way. Uninstalling RStudio doesn't get rid of the configuration files. I'm only aware of the ones you already deleted while resetting RStudios state but there might be more left from an old install. You can try uninstalling with the purge command to see if it helps getting rid of those.
sudo apt purge rstudio
Most likely some environment variable is not being set correctly on startup or you have an incompatible system dependency that is not being correctly reported by the error messages.
About the environment variables, there is little I can do for you because there are tons of them and I don't fully understand how the RStudio IDE initialize them, although, you could try creating a new system user and try to launch from that account to see if the problem is with your specific user's environment.
And to explore the second possibility, can you confirm that you have used the correct installer for your Ubuntu version? there are separate installers for Ubuntu 18+ and Ubuntu 22 (because they have different system dependencies).
thanks everyone for your help!
i installed ubuntu in 2020 and updated regularly...
i had some issue moving from r4.0 to r4.2 and I guess I made some mistakes there.
for some time, I kept installing r and ending up with version 4.0 instead of 4.2. that was the only issue and studio always worked properly (even r packages and everything else).
if you run out of suggestions, I guess that backing up my file and starting with a fresh ubuntu installation would be the best solution.
If you go this way I would recommend going with the latest Long Term Support (LTS) version (22.04.1 LTS) rather than the latest and greatest. RStudio fully supports LTS versions only.