metaborg/spoofax-intellij

Tree builder offset was not reset, race condition?

Opened this issue · 0 comments

IDE error after build (failed)

I tried to do this:

Build a simple project.

I expected this to happen:

No errors.

Instead, this happened:

Got this error in the IDE:

Error while indexing /home/daniel/IdeaProjects/untitled3/src-gen/ds-signatures/Common-sig.ds
To reindex this file IDEA has to be restarted: Tree builder offset was not reset, race condition?
java.lang.AssertionError: Tree builder offset was not reset, race condition?
	at org.spoofax.jsglr.client.imploder.TreeBuilder.initializeInput(TreeBuilder.java:122)
	at org.spoofax.jsglr.client.SGLR.initParseVariables(SGLR.java:704)
	at org.spoofax.jsglr.client.SGLR.parse(SGLR.java:530)
	at org.spoofax.jsglr.client.ParseTable.parseProductionAttributes(ParseTable.java:352)
	at org.spoofax.jsglr.client.ParseTable.parseLabels(ParseTable.java:226)
	at org.spoofax.jsglr.client.ParseTable.parse(ParseTable.java:137)
	at org.spoofax.jsglr.client.ParseTable.<init>(ParseTable.java:106)
	at org.metaborg.spoofax.core.syntax.FileParseTableProvider.parseTable(FileParseTableProvider.java:38)
	at org.metaborg.spoofax.core.syntax.JSGLRI.<init>(JSGLRI.java:49)
	at org.metaborg.spoofax.core.syntax.JSGLRParseService.parse(JSGLRParseService.java:86)
	at org.metaborg.spoofax.core.syntax.JSGLRParseService.parse(JSGLRParseService.java:1)
	at org.metaborg.core.syntax.SyntaxService.parse(SyntaxService.java:38)
	at org.metaborg.core.syntax.ISyntaxService.parse(ISyntaxService.java:59)
	at org.metaborg.intellij.idea.parsing.SpoofaxHighlightingLexer.parseAll(SpoofaxHighlightingLexer.java:154)
	at org.metaborg.intellij.idea.parsing.SpoofaxHighlightingLexer.start(SpoofaxHighlightingLexer.java:137)
	at com.intellij.openapi.editor.ex.util.LexerEditorHighlighter.doSetText(LexerEditorHighlighter.java:336)
	at com.intellij.openapi.editor.ex.util.LexerEditorHighlighter.setText(LexerEditorHighlighter.java:317)
	at com.intellij.psi.impl.cache.impl.id.PlatformIdTableBuilding$TokenSetTodoIndexer.map(PlatformIdTableBuilding.java:165)
	at com.intellij.psi.impl.cache.impl.id.PlatformIdTableBuilding$TokenSetTodoIndexer.map(PlatformIdTableBuilding.java:142)
	at com.intellij.psi.impl.cache.impl.todo.TodoIndex$4.map(TodoIndex.java:108)
	at com.intellij.psi.impl.cache.impl.todo.TodoIndex$4.map(TodoIndex.java:100)
	at com.intellij.util.indexing.MapReduceIndex.update(MapReduceIndex.java:461)
	at com.intellij.util.indexing.FileBasedIndexImpl.updateSingleIndex(FileBasedIndexImpl.java:1631)
	at com.intellij.util.indexing.FileBasedIndexImpl.lambda$doIndexFileContent$16(FileBasedIndexImpl.java:1567)
	at com.intellij.openapi.fileTypes.impl.FileTypeManagerImpl.freezeFileTypeTemporarilyIn(FileTypeManagerImpl.java:507)
	at com.intellij.util.indexing.FileBasedIndexImpl.doIndexFileContent(FileBasedIndexImpl.java:1528)
	at com.intellij.util.indexing.FileBasedIndexImpl.indexFileContent(FileBasedIndexImpl.java:1513)
	at com.intellij.util.indexing.FileBasedIndexImpl.processRefreshedFile(FileBasedIndexImpl.java:1493)
	at com.intellij.util.indexing.FileBasedIndexProjectHandler.lambda$reindexRefreshedFiles$2(FileBasedIndexProjectHandler.java:157)
	at com.intellij.openapi.project.CacheUpdateRunner$MyRunnable.lambda$run$0(CacheUpdateRunner.java:235)
	at com.intellij.openapi.application.impl.ApplicationImpl.tryRunReadAction(ApplicationImpl.java:1054)
	at com.intellij.openapi.project.CacheUpdateRunner$MyRunnable.lambda$run$1(CacheUpdateRunner.java:252)
	at com.intellij.openapi.progress.impl.CoreProgressManager$3.run(CoreProgressManager.java:179)
	at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:568)
	at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:519)
	at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:54)
	at com.intellij.openapi.progress.impl.CoreProgressManager.runProcess(CoreProgressManager.java:164)
	at com.intellij.openapi.project.CacheUpdateRunner$MyRunnable.run(CacheUpdateRunner.java:248)
	at com.intellij.openapi.application.impl.ApplicationImpl$2.run(ApplicationImpl.java:309)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
	at java.lang.Thread.run(Thread.java:745)

Spoofax 2.3.0