java.lang.IllegalStateException

parentByStub must not be null

Samebug tips0

We couldn't find tips for this exception.

Don't give up yet. Paste your full stack trace to get a solution.

Solutions on the web3

  • via GitHub by Jezza
    ,
  • via GitHub by Riateche
    ,
  • via GitHub by Riateche
    ,
  • Stack trace

    • java.lang.IllegalStateException: parentByStub must not be null at org.rust.lang.core.psi.impl.RustStubbedElementImpl.getParent(RustStubbedElementImpl.kt:18) at com.intellij.psi.impl.PsiElementBase.isValid(PsiElementBase.java:254) at com.intellij.extapi.psi.StubBasedPsiElementBase.isValid(StubBasedPsiElementBase.java:278) at com.intellij.psi.impl.PsiElementBase.isValid(PsiElementBase.java:258) at com.intellij.psi.impl.PsiElementBase.isValid(PsiElementBase.java:258) at com.intellij.extapi.psi.StubBasedPsiElementBase.isValid(StubBasedPsiElementBase.java:278) at com.intellij.psi.impl.PsiElementBase.isValid(PsiElementBase.java:258) at com.intellij.psi.impl.PsiElementBase.isValid(PsiElementBase.java:258) at com.intellij.psi.impl.PsiElementBase.isValid(PsiElementBase.java:258) at com.intellij.psi.impl.PsiElementBase.isValid(PsiElementBase.java:258) at com.intellij.psi.impl.PsiElementBase.isValid(PsiElementBase.java:258) at com.intellij.psi.impl.PsiElementBase.isValid(PsiElementBase.java:258) at com.intellij.psi.impl.PsiElementBase.isValid(PsiElementBase.java:258) at com.intellij.psi.impl.PsiElementBase.isValid(PsiElementBase.java:258) at com.intellij.psi.impl.PsiElementBase.isValid(PsiElementBase.java:258) at com.intellij.psi.impl.smartPointers.SmartPointerManagerImpl.updatePointerTarget(SmartPointerManagerImpl.java:260) at com.intellij.psi.impl.smartPointers.SmartPointerManagerImpl.updatePointerTargetsAfterReparse(SmartPointerManagerImpl.java:251) at com.intellij.psi.impl.PsiDocumentManagerBase.finishCommitInWriteAction(PsiDocumentManagerBase.java:344) at com.intellij.psi.impl.PsiDocumentManagerImpl.finishCommitInWriteAction(PsiDocumentManagerImpl.java:143) at com.intellij.psi.impl.PsiDocumentManagerBase$3.run(PsiDocumentManagerBase.java:298) at com.intellij.openapi.application.impl.ApplicationImpl.runWriteAction(ApplicationImpl.java:1010) at com.intellij.psi.impl.PsiDocumentManagerBase.finishCommit(PsiDocumentManagerBase.java:295) at com.intellij.psi.impl.DocumentCommitThread$5.run(DocumentCommitThread.java:528) at com.intellij.openapi.application.impl.LaterInvocator$FlushQueue.runNextEvent(LaterInvocator.java:337) at com.intellij.openapi.application.impl.LaterInvocator$FlushQueue.run(LaterInvocator.java:321) at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:311) at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:756) at java.awt.EventQueue.access$500(EventQueue.java:97) at java.awt.EventQueue$3.run(EventQueue.java:709) at java.awt.EventQueue$3.run(EventQueue.java:703) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:75) at java.awt.EventQueue.dispatchEvent(EventQueue.java:726) at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:866) at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:654) at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:381) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:201) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93) at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)

    Write tip

    You have a different solution? A short tip here would help you and many other users who saw this issue last week.

    Users with the same issue

    We couldn't find other users who have seen this exception.