Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Query sync: NPE in external repository labels resolution #6961

Closed
tpasternak opened this issue Nov 5, 2024 · 0 comments · Fixed by #6962
Closed

Query sync: NPE in external repository labels resolution #6961

tpasternak opened this issue Nov 5, 2024 · 0 comments · Fixed by #6962
Assignees
Labels
awaiting-maintainer Awaiting review from Bazel team on issues type: bug

Comments

@tpasternak
Copy link
Collaborator

Description of the bug:

com.google.idea.blaze.base.qsync.NotSupportedWithQuerySyncException: getBlazeInfo
	at com.google.idea.blaze.base.qsync.QuerySyncProjectData.getBlazeInfo(QuerySyncProjectData.java:143)
	at com.google.idea.blaze.base.sync.workspace.WorkspaceHelper.resolveExternalWorkspaceRoot(WorkspaceHelper.java:221)
	at com.google.idea.blaze.base.sync.workspace.WorkspaceHelper.resolveBlazePackage(WorkspaceHelper.java:88)
	at com.google.idea.blaze.base.lang.buildfile.references.BuildReferenceManager.resolveLabel(BuildReferenceManager.java:76)
	at com.google.idea.blaze.base.lang.buildfile.references.BuildReferenceManager.resolveLabel(BuildReferenceManager.java:70)
	at com.google.idea.blaze.base.lang.buildfile.references.LabelReference.resolveTarget(LabelReference.java:71)
	at com.google.idea.blaze.base.lang.buildfile.references.LabelReference.resolve(LabelReference.java:56)
	at com.google.idea.blaze.base.lang.buildfile.references.LoadedSymbolReference.resolve(LoadedSymbolReference.java:43)
	at com.google.idea.blaze.base.lang.buildfile.references.LoadedSymbolReference.resolve(LoadedSymbolReference.java:31)
	at com.google.idea.blaze.base.lang.buildfile.psi.BuildElementImpl.getReferencedElement(BuildElementImpl.java:104)
	at com.google.idea.blaze.base.lang.buildfile.psi.LoadedSymbol.getVisibleElement(LoadedSymbol.java:67)
	at com.google.idea.blaze.base.lang.buildfile.search.ResolveUtil.lambda$findInScope$0(ResolveUtil.java:86)
	at com.google.idea.blaze.base.lang.buildfile.psi.BuildFile.searchSymbolsInScope(BuildFile.java:227)
	at com.google.idea.blaze.base.lang.buildfile.search.ResolveUtil.searchInScope(ResolveUtil.java:46)
	at com.google.idea.blaze.base.lang.buildfile.search.ResolveUtil.findInScope(ResolveUtil.java:95)
	at com.google.idea.blaze.base.lang.buildfile.references.FuncallReference.resolve(FuncallReference.java:42)
	at com.google.idea.blaze.base.lang.buildfile.references.FuncallReference.resolve(FuncallReference.java:31)
	at com.google.idea.blaze.base.lang.buildfile.psi.BuildElementImpl.getReferencedElement(BuildElementImpl.java:104)
	at com.google.idea.blaze.base.lang.buildfile.validation.BuiltInRuleAnnotator.visitFuncallExpression(BuiltInRuleAnnotator.java:46)
	at com.google.idea.blaze.base.lang.buildfile.psi.FuncallExpression.acceptVisitor(FuncallExpression.java:50)
	at com.google.idea.blaze.base.lang.buildfile.psi.BuildElementImpl.accept(BuildElementImpl.java:91)
	at com.google.idea.blaze.base.lang.buildfile.validation.BuildAnnotator.annotate(BuildAnnotator.java:37)
	at com.intellij.codeInsight.daemon.impl.AnnotationHolderImpl.runAnnotatorWithContext(AnnotationHolderImpl.java:216)
	at com.intellij.codeInsight.daemon.impl.AnnotatorRunner.lambda$runAnnotator$2(AnnotatorRunner.java:130)
	at com.intellij.codeInsight.daemon.impl.AnnotationSessionImpl.computeWithSession(AnnotationSessionImpl.java:87)
	at com.intellij.codeInsight.daemon.impl.AnnotatorRunner.runAnnotator(AnnotatorRunner.java:120)
	at com.intellij.codeInsight.daemon.impl.AnnotatorRunner.lambda$runAnnotatorsAsync$0(AnnotatorRunner.java:67)
	at com.intellij.openapi.application.impl.AnyThreadWriteThreadingSupport.tryRunReadAction(AnyThreadWriteThreadingSupport.kt:333)
	at com.intellij.openapi.application.impl.ApplicationImpl.tryRunReadAction(ApplicationImpl.java:971)
	at com.intellij.codeInsight.daemon.impl.AnnotatorRunner.lambda$runAnnotatorsAsync$1(AnnotatorRunner.java:67)
	at com.intellij.concurrency.ApplierCompleter.processArrayItem(ApplierCompleter.java:126)
	at com.intellij.concurrency.ApplierCompleter.processArray(ApplierCompleter.java:207)
	at com.intellij.concurrency.ApplierCompleter.helpOthers(ApplierCompleter.java:227)
	at com.intellij.concurrency.ApplierCompleter.helpAll(ApplierCompleter.java:186)
	at com.intellij.concurrency.ApplierCompleter.lambda$exec$0(ApplierCompleter.java:116)
	at com.intellij.openapi.application.impl.AnyThreadWriteThreadingSupport.tryRunReadAction(AnyThreadWriteThreadingSupport.kt:351)
	at com.intellij.openapi.application.impl.ApplicationImpl.tryRunReadAction(ApplicationImpl.java:971)
	at com.intellij.concurrency.ApplierCompleter.lambda$wrapInReadActionAndIndicator$2(ApplierCompleter.java:158)
	at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$executeProcessUnderProgress$14(CoreProgressManager.java:674)
	at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:749)
	at com.intellij.openapi.progress.impl.CoreProgressManager.computeUnderProgress(CoreProgressManager.java:705)
	at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:673)
	at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:79)
	at com.intellij.concurrency.ApplierCompleter.wrapInReadActionAndIndicator(ApplierCompleter.java:169)
	at com.intellij.concurrency.ApplierCompleter.lambda$wrapAndRun$1(ApplierCompleter.java:150)
	at com.intellij.openapi.application.impl.AnyThreadWriteThreadingSupport.executeByImpatientReader(AnyThreadWriteThreadingSupport.kt:544)
	at com.intellij.openapi.application.impl.ApplicationImpl.executeByImpatientReader(ApplicationImpl.java:176)
	at com.intellij.concurrency.ApplierCompleter.wrapAndRun(ApplierCompleter.java:150)
	at com.intellij.concurrency.ApplierCompleter.exec(ApplierCompleter.java:118)
	at java.base/java.util.concurrent.ForkJoinTask.doExec$$$capture(ForkJoinTask.java:507)
	at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java)
	at --- Async.Stack.Trace --- (captured by IntelliJ IDEA debugger)
	at java.base/java.util.concurrent.ForkJoinTask.fork(ForkJoinTask.java)
	at com.intellij.concurrency.JobLauncherImpl.invokeConcurrentlyUnderProgressAsync(JobLauncherImpl.java:98)
	at com.intellij.concurrency.JobLauncherImpl.processConcurrentlyAsync(JobLauncherImpl.java:467)
	at com.intellij.codeInsight.daemon.impl.AnnotatorRunner.runAnnotatorsAsync(AnnotatorRunner.java:68)
	at com.intellij.codeInsight.daemon.impl.GeneralHighlightingPass.collectHighlights(GeneralHighlightingPass.java:252)
	at com.intellij.codeInsight.daemon.impl.GeneralHighlightingPass.lambda$collectInformationWithProgress$12(GeneralHighlightingPass.java:185)
	at com.intellij.codeInsight.daemon.impl.HighlightInfoUpdaterImpl.lambda$runWithInvalidPsiRecycler$34(HighlightInfoUpdaterImpl.java:718)
	at com.intellij.codeInsight.daemon.impl.ManagedHighlighterRecycler.runWithRecycler(ManagedHighlighterRecycler.java:85)
	at com.intellij.codeInsight.daemon.impl.HighlightInfoUpdaterImpl.runWithInvalidPsiRecycler(HighlightInfoUpdaterImpl.java:700)
	at com.intellij.codeInsight.daemon.impl.GeneralHighlightingPass.lambda$collectInformationWithProgress$13(GeneralHighlightingPass.java:210)
	at com.intellij.codeInsight.daemon.impl.HighlightVisitorRunner.createHighlightVisitorsFor(HighlightVisitorRunner.java:83)
	at com.intellij.codeInsight.daemon.impl.GeneralHighlightingPass.collectInformationWithProgress(GeneralHighlightingPass.java:107)
	at com.intellij.codeInsight.daemon.impl.ProgressableTextEditorHighlightingPass.doCollectInformation(ProgressableTextEditorHighlightingPass.java:86)
	at com.intellij.codeHighlighting.TextEditorHighlightingPass.collectInformation(TextEditorHighlightingPass.java:67)
	at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.lambda$doRun$2(PassExecutorService.java:427)
	at com.intellij.platform.diagnostic.telemetry.helpers.TraceKt.use(trace.kt:30)
	at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.lambda$doRun$3(PassExecutorService.java:423)
	at com.intellij.openapi.application.impl.AnyThreadWriteThreadingSupport.tryRunReadAction(AnyThreadWriteThreadingSupport.kt:351)
	at com.intellij.openapi.application.impl.ApplicationImpl.tryRunReadAction(ApplicationImpl.java:971)
	at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.lambda$doRun$4(PassExecutorService.java:413)
	at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$executeProcessUnderProgress$14(CoreProgressManager.java:674)
	at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:749)
	at com.intellij.openapi.progress.impl.CoreProgressManager.computeUnderProgress(CoreProgressManager.java:705)
	at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:673)
	at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:79)
	at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.doRun(PassExecutorService.java:412)
	at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.lambda$run$0(PassExecutorService.java:388)
	at com.intellij.openapi.fileTypes.impl.FileTypeManagerImpl.cacheFileTypesInside(FileTypeManagerImpl.java:822)
	at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.lambda$run$1(PassExecutorService.java:388)
	at com.intellij.openapi.application.impl.AnyThreadWriteThreadingSupport.executeByImpatientReader(AnyThreadWriteThreadingSupport.kt:544)
	at com.intellij.openapi.application.impl.ApplicationImpl.executeByImpatientReader(ApplicationImpl.java:176)
	at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.run(PassExecutorService.java:386)
	at com.intellij.concurrency.JobLauncherImpl$VoidForkJoinTask$1.exec(JobLauncherImpl.java:266)
	at java.base/java.util.concurrent.ForkJoinTask.doExec$$$capture(ForkJoinTask.java:507)
	at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java)
	at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1491)
	at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:2073)
	at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:2035)
	at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:187)

Related to #6843

Which category does this issue belong to?

No response

What's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.

No response

Which Intellij IDE are you using? Please provide the specific version.

No response

What programming languages and tools are you using? Please provide specific versions.

No response

What Bazel plugin version are you using?

No response

Have you found anything relevant by searching the web?

No response

Any other information, logs, or outputs that you want to share?

No response

@tpasternak tpasternak added type: bug awaiting-maintainer Awaiting review from Bazel team on issues labels Nov 5, 2024
tpasternak added a commit to tpasternak/bazel-intellij that referenced this issue Nov 5, 2024
…pace labels

For now, we have to just disable that.

closes bazelbuild#6961
@github-project-automation github-project-automation bot moved this from Untriaged to Done in Bazel IntelliJ Plugin Nov 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting-maintainer Awaiting review from Bazel team on issues type: bug
Projects
Development

Successfully merging a pull request may close this issue.

4 participants