False compilation errors repeatedly


It's a well know issue that IntelliJ shows false compilation errors, the solution to which has been proposed by IntelliJ team is to invalidate the cache, restart and retry.

But every time I invalidate the cache, it shows a false compilation error at another place and then another place in the project. How many times is one supposed to do this workaround fix? 100 times??

Is this supposed to be a behavior in the paid version of IntelliJ? There should be a better permanent fix to resolve this.


Links: https://intellij-support.jetbrains.com/hc/en-us/community/posts/206251519-False-compile-error



If possible, please provide a sample project and steps to reproduce the issue. It would be of great help.
Also, please provide your IDE logs (Help > Collect Logs and Diagnostic Data). You can use https://uploads.jetbrains.com/ to upload both, just provide your file upload ID.

As a workaround you can try the following steps:

  • Close project window in IntelliJ (File > Close Project) and close the IDE
  • Open your project in file explorer, backup and remove/delete all *.iml files and .idea folder
  • Backup and delete the system directory (all your settings will be preserved except local history)
  • Start IntelliJ and re-import the project from external sources.

HI Ivan Pajic - Thank you for your prompt response. I followed your instructions and I was able to resolve the problem but it helped only for a day or two. Now I have started seeing false compilation errors all over again. Invalidating cache and restarting IDE isn't helping either. I have uploaded IDE logs (UploadID: 2023_02_15_eqTcHwTP74SZJBPFG6NMYX).

The repo I am working on is a private repo so won't be able to provide it.

Thank you.





From the log file, I can see that you are using IntelliJ version 2021.2.4 (IU-212.5712.43) which is more than a year old. Is it possible to update to the latest version?
It could be that the issue is already fixed by changes in the newer versions.


Hi Ivan, does one have to reformat the hard drive and find the tape backups too?


Hi Jochen. That is not necessary.

Some issues with similar symptoms are resolved for good after re-creating project configuration files (especially in older versions) that's why we recommend it as the initial solution. If re-importing and updating doesn't help, the issue requires deeper analysis, hence our ask for IDE logs and a repro project.


Ivan Pajic „remove/delete all *.iml files and .idea folder“ — That is quite the aggressive workaround as you loose quite a lot of personal configuration that that way. 


Martin Krischik 
Unfortunately, without a reproducible scenario/sample, it is hard to find the root cause of the issue. The workaround is aggressive, but still could help to resolve the issue. Also, we recommend backing up the project metadata before deleting it, so that it can be potentially restored gradually without reintroducing the issue.


The same issue: 

Upload id: 2024_04_19_LsVRYMYDYciBPz8aEtMm6W (file: idea-logs-20240419-17375912268119836153620065.zip)


Katelusto Please file a new bug at https://youtrack.jetbrains.com/newIssue?project=IDEA. Provide a sample project / steps to reproduce in addition to the logs.


I am having the same issue. Inteliji told me to restart and since I can no longer compile any .java file it tells me files are not there when they are so many errors that makes no sense  I deleted the .iml and .ide folders removed the system file still in vein . Files that we did not  touch and used o compile fine are not working. I tried the suggested solution Import from External source in Vein  


Please help we are stuck  Iteliji 2022.3.2


Santexia Need more details. Contact support at https://intellij-support.jetbrains.com/hc/requests/new with the logs (Help | Collect Logs and Diagnostic Data) and a sample project to reproduce the issue. See if it's still occurring in the current release version: https://www.jetbrains.com/idea/download/index.html .


Please sign in to leave a comment.