HighlightInfoFilter cause NPE
Answered
hi, when I use HighlightInfoFilter for Vue code, the following error occurs, after debugging, I found that the filtered highligh info will become null, which will trigger NPE during internal traversal. The holder list will hold a null reference, causing an error in ContainerUtil.exists()
2024-01-03 16:00:37,705 [ 89136] SEVERE - #c.i.c.d.i.PassExecutorService - Cannot invoke "com.intellij.codeInsight.daemon.impl.HighlightInfo.getSeverity()" because "info" is null
java.lang.NullPointerException: Cannot invoke "com.intellij.codeInsight.daemon.impl.HighlightInfo.getSeverity()" because "info" is null
at com.intellij.lang.javascript.service.highlighting.JSLanguageServiceAnnotationProvider.lambda$updateWolfTheProblemSolver$0(JSLanguageServiceAnnotationProvider.java:59)
at com.intellij.util.containers.ContainerUtil.exists(ContainerUtil.java:2258)
at com.intellij.lang.javascript.service.highlighting.JSLanguageServiceAnnotationProvider.updateWolfTheProblemSolver(JSLanguageServiceAnnotationProvider.java:59)
at com.intellij.lang.javascript.service.highlighting.JSLanguageServiceHighlightingPass.doCollectInformation(JSLanguageServiceHighlightingPass.java:56)
at com.intellij.codeHighlighting.TextEditorHighlightingPass.collectInformation(TextEditorHighlightingPass.java:55)
at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.lambda$doRun$1(PassExecutorService.java:406)
at com.intellij.platform.diagnostic.telemetry.helpers.TraceKt.runWithSpanIgnoreThrows(trace.kt:76)
at com.intellij.platform.diagnostic.telemetry.helpers.TraceUtil.runWithSpanThrows(TraceUtil.java:34)
at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.lambda$doRun$2(PassExecutorService.java:401)
at com.intellij.openapi.application.impl.ApplicationImpl.tryRunReadAction(ApplicationImpl.java:1075)
at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.lambda$doRun$3(PassExecutorService.java:392)
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.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.doRun(PassExecutorService.java:391)
at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.lambda$run$0(PassExecutorService.java:367)
at com.intellij.openapi.application.impl.ReadMostlyRWLock.executeByImpatientReader(ReadMostlyRWLock.java:200)
at com.intellij.openapi.application.impl.ApplicationImpl.executeByImpatientReader(ApplicationImpl.java:184)
at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.run(PassExecutorService.java:365)
at com.intellij.concurrency.JobLauncherImpl$VoidForkJoinTask$1.exec(JobLauncherImpl.java:187)
at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:373)
at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1182)
at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1655)
at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1622)
at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:165)
Please sign in to leave a comment.
But HighlightInfoPostFilter works normally
Thanks, forwarded to developer.
Hello! Which IDE version do you use?
2023.3
It is a bug in processing the infos in JavaScript code base. Please, follow the issue https://youtrack.jetbrains.com/issue/WEB-65045