IntelliJ freezing on clicking the Run button

Answered

I've just “upgraded” from the IntelliJ Community edition to the Ultimate version. 

There's a very random and frequently occurring issue that makes the IDE unresponsive and requires termination of IDE via Task Manager. It happens after less than 10 uses of the “Run” button and is making this version / Edtion unusable. 

Any top tips as to how to fix? This was not happening on the Community edition

IntelliJ IDEA 2024.3 (Ultimate Edition)
Build #IU-243.21565.193, built on November 13, 2024 - running on Windows 11
 

6
38 comments
Hi Chris, in case of plugin conflict or cache issue, please follow the steps below to see if the issue persists or not.

• File | Invalidate Caches | Invalidate and Restart
• Follow the steps suggested by File | Repair IDE
• Temporarily disable all of the non-bundled plugins and restart the IDE: File | Settings | Plugins | ⚙ | Disable all downloaded plugins
• Manually re-generate project configuration settings:
1. Close the IDE, go to the project directory, backup and delete the entire `.idea` folder and any `.iml` files from its root 
2. In the IDE, go to File | New | Project from existing sources, select the project's source (root directory or main build file) 
3. Wait for indexing to finish

If the issue persists, please restart your IDE after freezing, and collect logs via Help | Collect Logs and Diagnostic Data. Upload the zip file to https://uploads.jetbrains.com/, and share the Upload ID with us.
0
Hi Chris, in case of plugin conflict or cache issue, please follow the steps below to see if the issue persists or not.

• File | Invalidate Caches | Invalidate and Restart
• Follow the steps suggested by File | Repair IDE
• Temporarily disable all of the non-bundled plugins and restart the IDE: File | Settings | Plugins | ⚙ | Disable all downloaded plugins
• Manually re-generate project configuration settings:
1. Close the IDE, go to the project directory, backup and delete the entire `.idea` folder and any `.iml` files from its root 
2. In the IDE, go to File | New | Project from existing sources, select the project's source (root directory or main build file) 
3. Wait for indexing to finish

If the issue persists, please restart your IDE after freezing, and collect logs via Help | Collect Logs and Diagnostic Data. Upload the zip file to https://uploads.jetbrains.com/, and share the Upload ID with us.
0

Thanks for these - I'll give them a go and update as necessary. 

I realise not part of your instructions. However, to clear down “Old” logs, is that just a matter of deleting files in the log directory or is there an IDE command to do this more “cleanly”?

0

Ok - unfortunately the IDE has frozen again. Zip file just uploaded.

Upload id: 2024_12_04_obn5XNjrsmRU31tfFpT7mn

Thanks for your help

0
Hi Chris, Thanks for sharing the logs. From the logs, we found some traces for freezing, and it's most likely caused by antivirus app.
May I know is there any antivirus app or safety protection app running in your machine? If yes, please try to disable them and work with JetBrains IDE again to see if the issue  persists or not.
Meanwhile, you can also add the following jetbrains related directories into the whitelist of these antivirus app or safety protection app.
- IDE installation path
- path of your project
- all the four directories mentioned in https://www.jetbrains.com/help/idea/directories-used-by-the-ide-to-store-settings-caches-plugins-and-logs.html
0

Thanks Jerome Guan 

Yes, I do have an antivirus running - Norton 360 = antivirus and firewall. Let me explore disabling that. Although I'm not sure that's an ideal solution for me. 

I'll also add those exclusions to a whitelist.  

I'll see if there's anything relevant in any local Norton logs that I can see.   

0

Hi Jerome Guan 

I've been testing with the AV and firewalls switched off. I'm still get the same freeze on “Run”. I've uploaded a fresh dump of the log files here … Upload ID: 2024_12_05_25uQe68s795MVtzzczJoPx It feels like a freeze during the build process. Hopefully the details in these logs might move things on?

I've also followed the steps on the two links below to add exclusions for IntelliJ into the Auto Protect and Process Protect features of Norton. I believe these steps cover the four directories in the link you shared. 

The last “freeze” in the log file upload was with those exclusions added, Auto-Protect and the Firewall switched off. 

I've followed these steps on Norton:

  1. https://intellij-support.jetbrains.com/hc/en-us/articles/360006298560-Antivirus-Impact-on-Build-Speed 
  2. https://intellij-support.jetbrains.com/hc/en-us/articles/360005028939-Slow-startup-on-Windows-splash-screen-appears-in-more-than-20-seconds 
0

For what it's worth, I re-opened the Project in the Community Edition and repeatedly tried to replicate the same issue in the same way I can in Ultimate (it's hit and miss, but changing a loop size and multiple “Run”s seems to reproduce it). I couldn't. The Community Edition didn't freeze. 

0

I am having the same problem, it started after updating to IntelliJ IDEA 2024.3

0

Just recorded my screen. Upload id: 2024_12_05_gUHBBjXvALhywPjeWpG8YX (file: Rodrigo - 192.168.4.36 - Conexão de Área de Trabalho Remota 2024-12-05 17-19-15.mp4)

The IDE doesn't exact freeze, at least not until I try to open another file or try to close the IDE 

0
Hi, I found a similar issue reported in YouTrack https://youtrack.jetbrains.com/issue/IDEA-363384/After-running-same-Java-code-several-times-the-run-button-shows-a-spinner-forever
Please follow it to get latest update.

Meanwhile, I think rebuilding the project after run for several times may worth try cause everytime run the project, it will use preloaded build process, so rebuild may be an option to generate these build process again.
0

Thanks Jerome Guan - reading the title of the issue, it does sound similar to my experience in the Ultimate Edition. Unfortunately, the link you've shared gives a 404 and I can't find the issue number on searching in YouTrack. Please, would you share a link that works? I can't follow progress on it until then. 

Out of interest, are the build processes different between the Community and Ultimate Editions? That may indicate an avenue to explore. 

I'll try rebuilding my current project again. The original issue remains (spinner freezes on build that are forcing a terminate process and restart within 10 clicks of the “Run” button) and the IDE is frustrating to use because of it. UPDATE: the rebuild and repair lasted 5 clicks of the “Run” button before requiring termination. 

0

I can't open the issue link, returns error 404

0

Me neither but my update from earlier this AM is currently showing as “pending approval”. I'll repost in a bit if it remains in that state! 

0

Hi Jerome Guan - do you have a working version of that URL / other ideas to help resolve this, please? 

Also, since my previous update, I've uninstalled Ultimate and re-installed via  JetBrains Toolbox. The build freeze issue remains.  

UPDATE - I've updated IntelliJ to the version below and continue to get the build freeze.

IntelliJ IDEA 2024.3.1 (Ultimate Edition)
Build #IU-243.22562.145, built on December 9, 2024

0
Hi Chris, cause the YouTrack issue is set to non-public on visibility by the author. Today we've published 2024.3.1, could you please help to check if the issue persists in 2024.3.1 or not?
0

Understood re privacy on that youtrack issue. Do let us know if there's a solution or ideas shared on that thread. 

Re 2024.3.1, unfortunately, and as I shared yesterday, this update has not fixed the freeze on “Run” for me 

0

Jerome Guan and Bond Han … I wanted to provide an update and the link to the latest dump I've made of diagnostic data. 

Bond - this is the thread I mentioned on the other post. I'll happily open a a You Track ticket if you believe it's best to handle that way. 

I'm now running on 2024.3.1 and still have the freeze issue on at least one of my projects. This is the upload for the diagnostic data from that freeze that happened ~1020 local time this AM  … Upload id: 2024_12_12_rwBHu6CQg1vdv11hVUHUN1 

Since my last post, I have tried multiple “invalidate caches and restart”, started a new version of the project based on a clone from Git, disabled the AI plugin and reconfirmed scan exclusions on my anti-virus tool. 

I did yesterday, start building a new project (for something unrelated to the problem code ie totally different). In that project things are behaving far better - I've not yet had a freeze. However, as above, with the original code, even when cloning fresh from Git, I still get the freeze issue. 

0

I possibly spoke too soon, it's looking like the project I had yesterday was a one off. Another new project and it's exhibiting the freezes on run. I've uploaded log files in case the data holds something new / different. 

 Upload id: 2024_12_12_4yafhjjC2RPqNZg7XVJYeR 

0

From log “2024_12_12_rwBHu6CQg1vdv11hVUHUN1 ”, at around 1020 AM your local time, I didn't see a thread dump generated due to UI freezing, but I saw error about network issue - 

2024-12-12 10:21:48,644 [77238917]   INFO - STDERR - Caused by: java.rmi.UnmarshalException: Error unmarshaling return header; nested exception is: 
2024-12-12 10:21:48,644 [77238917]   INFO - STDERR -     java.net.SocketException: Connection reset

Does your project require inbound or outbound network activity? Does your anti-virus app also do network filtering? Is it possible to check its log at timeframe 1020-1021 to see what it actually did?

According to your description, it sounds like the issue is project-specific, in that case it might be worth checking the difference the code logic.

From log “2024_12_12_4yafhjjC2RPqNZg7XVJYeR ” , no dump got generated either. Could you also provide the timestamp of the latest occurance of the issue from this new log?

0

The project code itself (in all the examples I have to date) is self-contained in that there is no network activity required. The source code sits on a local NAS so will be read/writing to that during a build.

I've checked the anti-virus and nothing obvious in the logs there. Actually for any of the freezes that I've seen. I have the network locations, IntelliJ programs and processes whitelisted (as best as I can tell). 

re the 1020 issue - Can we see which port / connection IntelliJ is trying to make when the error is triggered?

The issue in the second log would have been around 1516 or so. I can see a threadDumps file timestamped to roughly then, if that's what you need. 

Does the Community Edition have a different build process or config parameters to Ultimate? Earlier in the week I went back to the Community version and didn't have a problem. 

0

Having similar symptoms.
Started happening after upgrade to 2024.3.1

Really simple project.
GUI freezes after few “Runs”.

2

Yes, still happening for me as well. Very straightforward code (70 odd lines all in a single Main class). The codebase was on my local machine (to remove any network usage), AV was off (so no auto-scanning) and I was disconnect from the internet. The build froze after very minor code changes. I'd reset caches and cleared the logs previously. I've uploaded the log files here Upload id: 2024_12_16_FeDudVDwHjF5iLYj1F7emq - all that's in there is the 7 or so “Run”s and the freeze. 

I've been trying to use the “Ultimate” version, with limited success, for nearly 2 weeks now. Please guide as to how this gets fixed? Is it worth a deep uninstall and re-install. (I'm clutching at straws - but open to try)    

0
Hi All, is it possible for you to share a sample project with us? Please remove all confidential information and personal data, and please let us know the JDK version / build tools you use.
Please upload to https://uploads.jetbrains.com/, and share the Upload ID with us.
0

I have also same symptoms.
Started happening after upgrade to 2024.3.x
2024.2.5 works stable

Really simple project, like a “hello world”. 
GUI freezes after few “Runs” and I need to kill it in task manager. 
Have tried to deactive all third party plugins, “repair IDE”, “invalidate caches and restart” , etc. Downgrade java version, tryed latest IDE JRE Runtime. Nothing helps. 
I really hate latest IntelliJ versions (that's not the only problem I've had in recent versions), they're getting less stable and glitchier every day  and it's time for the company to start thinking about making this IDE stable again….

1

I don't think the problem is in the project, because my test project that I run consists of only 1 class and it is very simple - filling an array in a loop and displaying it on the screen. I am using Java versions 20 and 23, official Oracle JDK and I have also tried third party JDK versions. Build tool maven 3.9.9 I have  windows os, ryzen 5950x cpu / 64 gb ddr4 and in general everything was stable until new IntelliJ IDE versions appeared.  New versions are a real disaster, they suddenly start to slow down everything, navigating files in project tree or IDE hangs during compilation and launching / run or suddenly IDE forgets font sizes and layout settings. I don't recommend version 2024.3 and older to anyone.. I don't understand what's going on with this IDE over the last time.

0

Jerome Guan I've uploaded a Zip of one of the projects I have that causes the freeze here - Upload id: 2024_12_17_uUmhkf3znghEiirmdd7oLH 

Similar to set up that others have detailed … very simple 70 odd lines of code all in a Main class.  Using openjdk-23 from Oracle (specifically version 23.0.1). The codebase I've shared is the one that generated the freeze I uploaded as notified in my post at 0913 yesterday, https://intellij-support.jetbrains.com/hc/en-us/community/posts/23046034767250/comments/23319306606866 “Upload id: 2024_12_16_FeDudVDwHjF5iLYj1F7emq - all that's in there is the 7 or so “Run"s and the freeze.”

I've been running the attached code in the Community edition without a freeze so far. 

0

I posted a reply earlier (13:39 local time) with a sample code link but it's still showing as “pending”

UPDATE Jerome Guan I shared a source code zip yesterday. My post is still showing as “pending approval”. Is that something you can approve, please? 

0

It appears that this problem occurs only on Windows, running Intellij inside WSL for a while and didn't have this problem yet

0
Many thanks, Chris. I can reproduce this issue with your project in 2024.3.1.1, I will share the sample project to devs for further troubleshooting.
4

Please sign in to leave a comment.