SchwarzIT/spectral-intellij-plugin

Error on IntelliJ startup

Closed this issue · 1 comments

Description:

Plugin error on IntelliJ startup. Below are env specs and stacktraces.

OS: Windows 11 Pro
IDE: IntelliJ IDEA 2022.3.1 (Ultimate Edition)
Java: 17.0.6 2023-01-17 LTS

Stacktraces:

com.intellij.diagnostic.PluginException: annotator: com.schwarzit.spectralIntellijPlugin.SpectralExternalAnnotator@33c8e931 (class com.schwarzit.spectralIntellijPlugin.SpectralExternalAnnotator) [Plugin: com.schwarzit.spectral-intellij-plugin]
	at com.intellij.diagnostic.PluginProblemReporterImpl.createPluginExceptionByClass(PluginProblemReporterImpl.java:23)
	at com.intellij.diagnostic.PluginException.createByClass(PluginException.java:83)
	at com.intellij.codeInsight.daemon.impl.ExternalToolPass.processError(ExternalToolPass.java:263)
	at com.intellij.codeInsight.daemon.impl.ExternalToolPass.collectInformationWithProgress(ExternalToolPass.java:138)
	at com.intellij.codeInsight.daemon.impl.ProgressableTextEditorHighlightingPass.doCollectInformation(ProgressableTextEditorHighlightingPass.java:97)
	at com.intellij.codeHighlighting.TextEditorHighlightingPass.collectInformation(TextEditorHighlightingPass.java:57)
	at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.lambda$doRun$1(PassExecutorService.java:379)
	at com.intellij.openapi.application.impl.ApplicationImpl.tryRunReadAction(ApplicationImpl.java:1086)
	at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.lambda$doRun$2(PassExecutorService.java:371)
	at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$executeProcessUnderProgress$13(CoreProgressManager.java:589)
	at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:664)
	at com.intellij.openapi.progress.impl.CoreProgressManager.computeUnderProgress(CoreProgressManager.java:620)
	at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:588)
	at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:60)
	at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.doRun(PassExecutorService.java:370)
	at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.lambda$run$0(PassExecutorService.java:346)
	at com.intellij.openapi.application.impl.ReadMostlyRWLock.executeByImpatientReader(ReadMostlyRWLock.java:173)
	at com.intellij.openapi.application.impl.ApplicationImpl.executeByImpatientReader(ApplicationImpl.java:182)
	at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.run(PassExecutorService.java:344)
	at com.intellij.concurrency.JobLauncherImpl$VoidForkJoinTask$1.exec(JobLauncherImpl.java:181)
	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)
Caused by: java.lang.UnsupportedOperationException: Failed to map LightVirtualFile: \Dummy.json (filesystem com.intellij.testFramework.LightVirtualFileBase$MyVirtualFileSystem@76641ed5) into nio Path
	at com.intellij.openapi.vfs.VirtualFile.toNioPath(VirtualFile.java:164)
	at com.schwarzit.spectralIntellijPlugin.SpectralExternalAnnotator.collectInformation(SpectralExternalAnnotator.java:57)
	at com.schwarzit.spectralIntellijPlugin.SpectralExternalAnnotator.collectInformation(SpectralExternalAnnotator.java:29)
	at com.intellij.lang.annotation.ExternalAnnotator.collectInformation(ExternalAnnotator.java:60)
	at com.intellij.codeInsight.daemon.impl.ExternalToolPass.collectInformationWithProgress(ExternalToolPass.java:135)
	... 21 more

Hi, thanks for your report, sorry for the delayed answer. We just released a new major version of the plugin. I'm closing this issue as it should be resolved with the new version.
Please feel free to try it out.
Please note, that we decided to no longer bundle the Spectral CLI within the plugin, so you'll have to install it on your system yourself.