ConcurrentModificationException in SonarLint for IntelliJ 10.0.1

For me it’s not freezing anymore. Instead I have:

Error running SonarLint analysis
java.util.ConcurrentModificationException
	at java.base/java.util.LinkedHashMap.forEach(LinkedHashMap.java:723)
	at org.sonarlint.intellij.finding.persistence.LiveFindingCache.flushAll(LiveFindingCache.java:141)
	at org.sonarlint.intellij.finding.persistence.LiveFindingCache.replaceFindings(LiveFindingCache.java:59)
	at org.sonarlint.intellij.finding.persistence.FindingsCache.replaceFindings(FindingsCache.java:100)
	at org.sonarlint.intellij.analysis.Analysis.doRun(Analysis.java:141)
	at org.sonarlint.intellij.analysis.Analysis.run(Analysis.java:79)
	at org.sonarlint.intellij.tasks.TaskRunnerKt$startBackgroundable$task$1.run(TaskRunner.kt:54)
	at com.intellij.openapi.progress.impl.CoreProgressManager.startTask(CoreProgressManager.java:434)
	at com.intellij.openapi.progress.impl.ProgressManagerImpl.startTask(ProgressManagerImpl.java:132)
	at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$runProcessWithProgressAsynchronously$5(CoreProgressManager.java:484)
	at com.intellij.codeWithMe.ClientId$Companion.decorateFunction$lambda$8(ClientId.kt:383)
	at com.intellij.codeWithMe.ClientId$Companion.decorateFunction$lambda$8(ClientId.kt:383)
	at com.intellij.openapi.progress.impl.ProgressRunner.lambda$submit$4(ProgressRunner.java:248)
	at com.intellij.openapi.progress.ProgressManager.lambda$runProcess$0(ProgressManager.java:73)
	at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$runProcess$1(CoreProgressManager.java:192)
	at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$executeProcessUnderProgress$12(CoreProgressManager.java:610)
	at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:685)
	at com.intellij.openapi.progress.impl.CoreProgressManager.computeUnderProgress(CoreProgressManager.java:641)
	at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:609)
	at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:78)
	at com.intellij.openapi.progress.impl.CoreProgressManager.runProcess(CoreProgressManager.java:179)
	at com.intellij.openapi.progress.ProgressManager.runProcess(ProgressManager.java:73)
	at com.intellij.openapi.progress.impl.ProgressRunner.lambda$submit$5(ProgressRunner.java:248)
	at com.intellij.openapi.progress.impl.ProgressRunner$ProgressRunnable.run(ProgressRunner.java:498)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
	at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:702)
	at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:699)
	at java.base/java.security.AccessController.doPrivileged(AccessController.java:399)
	at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1.run(Executors.java:699)
	at java.base/java.lang.Thread.run(Thread.java:840)

Hi @cysieks,

We are already aware of this problem, and we will fix it for the release at the end of the month.

How often do you observe it?

Hi,

I’m getting the same issue.

It happens in two situations

  1. when I try to analyze all project files
  2. when an analysis of a single file is running because of the automatic setting and I then trigger the analysis manually in the current file tab while the analysis is still running.

I also observe that the analysis takes forever.

Note: My SonarLint is connected to a SonarQube server (my client is running this server inhouse).

It happens always. Project analysis is impossible.

1 Like

Hi @AlexisKyaw,

Thanks for reaching out. We just released a new version that fixes the ConcurrentModificationException. Could you give it a try?

I also observe that the analysis takes forever.

If it’s still the case after the update, may I ask you to open a separate topic?

I tried the updated plugin with the unfortunate result that while the exception has gone, now IntelliJ freezes once I click on the first issue/once I click in the editor at the highlighted position to fix the error.

Could you please open a separate thread and send us a thread dump captured when the IDE is frozen? It will help us understand what’s going on. Thanks

New issue with Threaddump: