MPSPsiRootNode

Hi,

We build a product on IntelliJ and create a mps language that is installed as plugin.

After we update de intellij and mps to 2017.3.5 we have several problems.

Right now we are blocked, when we try open a node this error appears:


ERROR - mps.smodel.EDTExecutorInternal - run in EDT failure
java.lang.IllegalArgumentException: Argument for @NotNull parameter 'virtualFile' of jetbrains/mps/idea/core/psi/impl/MPSPsiRootNode.<init> must not be null
at jetbrains.mps.idea.core.psi.impl.MPSPsiRootNode.$$$reportNull$$$0(MPSPsiRootNode.java)
at jetbrains.mps.idea.core.psi.impl.MPSPsiRootNode.<init>(MPSPsiRootNode.java)
at jetbrains.mps.idea.core.psi.impl.MPSPsiModel.reload(MPSPsiModel.java:433)
at jetbrains.mps.idea.core.psi.impl.MPSPsiProvider.getMPSPsiModel(MPSPsiProvider.java:230)
at jetbrains.mps.idea.core.psi.impl.MPSPsiProvider.getPsi(MPSPsiProvider.java:167)
at jetbrains.mps.idea.core.psi.impl.MPSPsiProvider.getPsi(MPSPsiProvider.java:154)
at jetbrains.mps.idea.core.navigation.NavigationSupportImpl.navigatedToIdea(NavigationSupportImpl.java:77)
at jetbrains.mps.idea.core.navigation.NavigationSupportImpl.openNode(NavigationSupportImpl.java:55)
at pt.i2s.ibml.navigation.I2SNavigationSupport.lambda$openRootNode$0(I2SNavigationSupport.java:49)
at jetbrains.mps.smodel.WorkbenchModelAccess$CommandRunnable.lambda$run$0(WorkbenchModelAccess.java:449)
at jetbrains.mps.smodel.WorkbenchModelAccess.runWriteAction(WorkbenchModelAccess.java:97)
at jetbrains.mps.smodel.WorkbenchModelAccess$CommandRunnable.run(WorkbenchModelAccess.java:446)
at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:149)
at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:109)
at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:99)
at jetbrains.mps.smodel.WorkbenchModelAccess.runWriteActionInCommand(WorkbenchModelAccess.java:311)
at jetbrains.mps.smodel.WorkbenchModelAccess.executeCommand(WorkbenchModelAccess.java:307)
at jetbrains.mps.project.ProjectModelAccess.executeCommand(ProjectModelAccess.java:43)
at pt.i2s.ibml.navigation.I2SNavigationSupport.openRootNode(I2SNavigationSupport.java:46)
at pt.i2s.ibml.actions.IbmlActions.lambda$openRulesetInternal$4(IbmlActions.java:98)
at jetbrains.mps.smodel.WorkbenchModelAccess.lambda$tryWrite$6(WorkbenchModelAccess.java:199)
at jetbrains.mps.util.ComputeRunnable.compute(ComputeRunnable.java:32)
at jetbrains.mps.util.AbstractComputeRunnable.run(AbstractComputeRunnable.java:27)
at jetbrains.mps.smodel.WriteActionDispatcher.run(WriteActionDispatcher.java:39)
at jetbrains.mps.smodel.WriteActionDispatcher.compute(WriteActionDispatcher.java:49)
at jetbrains.mps.smodel.WorkbenchModelAccess.lambda$tryWrite$7(WorkbenchModelAccess.java:218)
at jetbrains.mps.util.ComputeRunnable.compute(ComputeRunnable.java:32)
at jetbrains.mps.util.AbstractComputeRunnable.run(AbstractComputeRunnable.java:27)
at jetbrains.mps.smodel.TryRunPlatformWriteHelper$TryWriteActionRunnable.lambda$tryWrite$0(TryRunPlatformWriteHelper.java:142)
at com.intellij.openapi.application.impl.ApplicationImpl.runWriteAction(ApplicationImpl.java:1004)
at jetbrains.mps.smodel.TryRunPlatformWriteHelper$TryWriteActionRunnable.tryWrite(TryRunPlatformWriteHelper.java:140)
at jetbrains.mps.smodel.TryRunPlatformWriteHelper.tryWrite(TryRunPlatformWriteHelper.java:121)
at jetbrains.mps.smodel.WorkbenchModelAccess.tryWrite(WorkbenchModelAccess.java:236)
at jetbrains.mps.smodel.WorkbenchModelAccess.tryWrite(WorkbenchModelAccess.java:202)
at jetbrains.mps.smodel.WorkbenchModelAccess.lambda$runWriteInEDT$3(WorkbenchModelAccess.java:151)
at jetbrains.mps.smodel.EDTExecutorInternal.tryToRunTopTask(EDTExecutorInternal.java:204)
at jetbrains.mps.smodel.EDTExecutorInternal.flushNTasks(EDTExecutorInternal.java:167)
at jetbrains.mps.smodel.EDTExecutorInternal.doFlush(EDTExecutorInternal.java:141)
at jetbrains.mps.smodel.EDTExecutorInternal.flushTasksQueue(EDTExecutorInternal.java:129)
at com.intellij.openapi.application.TransactionGuardImpl.runSyncTransaction(TransactionGuardImpl.java:88)
at com.intellij.openapi.application.TransactionGuardImpl.lambda$submitTransaction$1(TransactionGuardImpl.java:111)
at com.intellij.openapi.application.TransactionGuardImpl.submitTransaction(TransactionGuardImpl.java:120)
at com.intellij.openapi.application.TransactionGuardImpl.lambda$submitTransactionLater$4(TransactionGuardImpl.java:271)
at com.intellij.openapi.application.impl.LaterInvocator$FlushQueue.runNextEvent(LaterInvocator.java:424)
at com.intellij.openapi.application.impl.LaterInvocator$FlushQueue.run(LaterInvocator.java:407)
at java.awt.event.InvocationEvent.dispatch$$$capture(InvocationEvent.java:311)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:758)
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$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:80)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:728)
at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:822)
at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:650)
at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:366)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:205)
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)

Thanks

Eduardo

3
1 comment

Hello Eduardo,

Let me summarize:
1. You have MPS project with your langage
2. You migrated it to MPS 2017.3.5
3. Update build script to point Idea 2017.3.5 (idea_home) and mps plugins 2017.3.5 (plugins_home)
4. Using build script, packed it to Idea plugin
5. Install this plugin to Idea 2017.3.5
6. Open some project, that was created with previous version on Idea and mps plugins
7. Try to open some root and got an exception

Is that right?
Do you trying to open this root from project tree or from editor?

By analyzing stack trace, it seems that you trying to open some root in per-root persistence and plugin fails to find file for this root.
I tried to reproduce this, but can't do it on Idea 2017.3.5 with latest mps plugins for root in pre-root persistence, that is in project or packaged in plugin.

0

Please sign in to leave a comment.