Unscrambling stacktrace

hi jb developers

I have two stack traces triggered by calling PsiUtil.hasErrorElementChild. Could you please tell me what is null and what assertion is not fulfilled? They happened in build 6146. I'm not sure if there is something that I do wrong or if it's an IDEA issue...

thanks, etienne

java.lang.NullPointerException
at com.intellij.psi.impl.RepositoryElementsManager.a(RepositoryElementsManager.java:33)
at com.intellij.psi.impl.RepositoryElementsManager.a(RepositoryElementsManager.java:235)
at com.intellij.psi.impl.RepositoryElementsManager.getOrFindTreeElement(RepositoryElementsManager.java:1)
at com.intellij.psi.impl.source.SrcRepositoryPsiElement.calcTreeElement(SrcRepositoryPsiElement.java:82)
at com.intellij.psi.impl.source.TreeWrapperPsiElement.getFirstChild(TreeWrapperPsiElement.java:97)
at com.intellij.psi.util.PsiUtil.hasErrorElementChild(PsiUtil.java:1091)
at nu.studer.idea.inspection.NamingInspection.inspect(NamingInspection.java:244)
at nu.studer.idea.inspection.NamingInspection.checkMethod(NamingInspection.java:126)
at com.intellij.codeInsight.daemon.impl.LocalInspectionsPass.a(LocalInspectionsPass.java:68)
at com.intellij.codeInsight.daemon.impl.LocalInspectionsPass.doCollectInformation(LocalInspectionsPass.java:55)
at com.intellij.codeHighlighting.TextEditorHighlightingPass.collectInformation(TextEditorHighlightingPass.java:59)
at com.intellij.codeInsight.daemon.impl.UpdateThread$2.run(UpdateThread.java:10)
at com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:131)
at com.intellij.codeInsight.daemon.impl.UpdateThread.a(UpdateThread.java:30)
at com.intellij.codeInsight.daemon.impl.UpdateThread.access$100(UpdateThread.java:20)
at com.intellij.codeInsight.daemon.impl.UpdateThread$1.run(UpdateThread.java:3)
at com.intellij.openapi.progress.impl.ProgressManagerImpl.runProcess(ProgressManagerImpl.java:84)
at com.intellij.codeInsight.daemon.impl.UpdateThread.run(UpdateThread.java:33)

java.lang.Throwable
at com.intellij.openapi.diagnostic.Logger.assertTrue(Logger.java:89)
at com.intellij.openapi.diagnostic.Logger.assertTrue(Logger.java:96)
at com.intellij.psi.impl.RepositoryElementsManager.a(RepositoryElementsManager.java:5)
at com.intellij.psi.impl.RepositoryElementsManager.a(RepositoryElementsManager.java:235)
at com.intellij.psi.impl.RepositoryElementsManager.getOrFindTreeElement(RepositoryElementsManager.java:1)
at com.intellij.psi.impl.source.SrcRepositoryPsiElement.calcTreeElement(SrcRepositoryPsiElement.java:82)
at com.intellij.psi.impl.source.TreeWrapperPsiElement.getFirstChild(TreeWrapperPsiElement.java:97)
at com.intellij.psi.util.PsiUtil.hasErrorElementChild(PsiUtil.java:1091)
at nu.studer.idea.inspection.NamingInspection.inspect(NamingInspection.java:244)
at nu.studer.idea.inspection.NamingInspection.checkMethod(NamingInspection.java:126)
at com.intellij.codeInsight.daemon.impl.LocalInspectionsPass.a(LocalInspectionsPass.java:68)
at com.intellij.codeInsight.daemon.impl.LocalInspectionsPass.doCollectInformation(LocalInspectionsPass.java:55)
at com.intellij.codeHighlighting.TextEditorHighlightingPass.collectInformation(TextEditorHighlightingPass.java:59)
at com.intellij.codeInsight.daemon.impl.UpdateThread$2.run(UpdateThread.java:10)
at com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:131)
at com.intellij.codeInsight.daemon.impl.UpdateThread.a(UpdateThread.java:30)
at com.intellij.codeInsight.daemon.impl.UpdateThread.access$100(UpdateThread.java:20)
at com.intellij.codeInsight.daemon.impl.UpdateThread$1.run(UpdateThread.java:3)
at com.intellij.openapi.progress.impl.ProgressManagerImpl.runProcess(ProgressManagerImpl.java:84)
at com.intellij.codeInsight.daemon.impl.UpdateThread.run(UpdateThread.java:33)

2 comments
Comment actions Permalink

Problems with Repository* classes have a good chance of being "fixed" by cleaning IDEA's caches. In any case, it doesn't look like it's a plugin problem, unless the element you're passing to hasErrorElementChild() returns false from isValid().

Sascha

0
Comment actions Permalink

Thanks for the feedback. I previously test for isValid() .

etienne

0

Please sign in to leave a comment.