shlxue / MvnRunner

IntelliJ plugin for maven, building and run unit testing or main method, by mvn.
MIT License
7 stars 6 forks source link

IntelliJ 14 Exception #14

Closed ghost closed 9 years ago

ghost commented 9 years ago

update failed for ActionGroup: Test file (Run current File with Maven)[Test file]: org.jetbrains.idea.maven.project.MavenProjectsManager.getExplicitProfiles()Ljava/util/Collection; java.lang.NoSuchMethodError: org.jetbrains.idea.maven.project.MavenProjectsManager.getExplicitProfiles()Ljava/util/Collection; at com.lightd.ideap.maven.execution.MavenModuleConfigurationProducer.createMavenParameters(MavenModuleConfigurationProducer.java:78) at com.lightd.ideap.maven.execution.MavenModuleConfigurationProducer.setupConfigurationFromContext(MavenModuleConfigurationProducer.java:53) at com.lightd.ideap.maven.execution.MavenModuleConfigurationProducer.setupConfigurationFromContext(MavenModuleConfigurationProducer.java:27) at com.intellij.execution.actions.RunConfigurationProducer.createConfigurationFromContext(RunConfigurationProducer.java:73) at com.intellij.execution.actions.RunConfigurationProducer.findOrCreateConfigurationFromContext(RunConfigurationProducer.java:139) at com.intellij.execution.actions.PreferredProducerFind.getConfigurationsFromContext(PreferredProducerFind.java:106) at com.intellij.execution.actions.PreferredProducerFind.findConfigurationFromContext(PreferredProducerFind.java:131) at com.intellij.execution.actions.PreferredProducerFind.createConfiguration(PreferredProducerFind.java:43) at com.intellij.execution.actions.ConfigurationContext.createConfiguration(ConfigurationContext.java:119) at com.intellij.execution.actions.ConfigurationContext.getConfiguration(ConfigurationContext.java:112) at krasa.mavenrun.action.RunTestFileAction.update(RunTestFileAction.java:91) at com.intellij.openapi.actionSystem.ex.ActionUtil.performDumbAwareUpdate(ActionUtil.java:113) at com.intellij.openapi.actionSystem.impl.Utils.a(Utils.java:188) at com.intellij.openapi.actionSystem.impl.Utils.updateGroupChild(Utils.java:265) at com.intellij.openapi.actionSystem.impl.Utils.a(Utils.java:239) at com.intellij.openapi.actionSystem.impl.Utils.a(Utils.java:205) at com.intellij.openapi.actionSystem.impl.Utils.expandActionGroup(Utils.java:153) at com.intellij.openapi.actionSystem.impl.Utils.expandActionGroup(Utils.java:164) at com.intellij.openapi.actionSystem.impl.Utils.expandActionGroup(Utils.java:86) at com.intellij.openapi.actionSystem.impl.Utils.fillMenu(Utils.java:280) at com.intellij.openapi.actionSystem.impl.ActionPopupMenuImpl$MyMenu.show(ActionPopupMenuImpl.java:96) at com.intellij.ide.ui.customization.CustomizationUtil$3.invokePopup(CustomizationUtil.java:291) at com.intellij.ui.PopupHandler.mouseReleased(PopupHandler.java:55) at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:290) at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:289) at java.awt.Component.processMouseEvent(Component.java:6525) at javax.swing.JComponent.processMouseEvent(JComponent.java:3321) at com.intellij.ui.treeStructure.Tree.processMouseEvent(Tree.java:421) at com.intellij.ide.dnd.aware.DnDAwareTree.processMouseEvent(DnDAwareTree.java:53) at java.awt.Component.processEvent(Component.java:6290) at java.awt.Container.processEvent(Container.java:2234) at java.awt.Component.dispatchEventImpl(Component.java:4881) at java.awt.Container.dispatchEventImpl(Container.java:2292) at java.awt.Component.dispatchEvent(Component.java:4703) at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4898) at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4533) at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4462) at java.awt.Container.dispatchEventImpl(Container.java:2278) at java.awt.Window.dispatchEventImpl(Window.java:2739) at java.awt.Component.dispatchEvent(Component.java:4703) at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:746) at java.awt.EventQueue.access$400(EventQueue.java:97) at java.awt.EventQueue$3.run(EventQueue.java:697) at java.awt.EventQueue$3.run(EventQueue.java:691) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:75) at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:86) at java.awt.EventQueue$4.run(EventQueue.java:719) at java.awt.EventQueue$4.run(EventQueue.java:717) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:75) at java.awt.EventQueue.dispatchEvent(EventQueue.java:716) at com.intellij.ide.IdeEventQueue.e(IdeEventQueue.java:748) at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:573) at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:384) 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)

krasa commented 9 years ago

Are you using 2.2.138.1503?

ghost commented 9 years ago

< idea-plugin version="2" url="https://github.com/ShlXue/MvnRunner"> < id>MvnRunner < name>Maven Runner < version>0.3.0 < vendor email="XueShuiliang@gmail.com" url="https://github.com/shlXue"/ >

krasa commented 9 years ago

Wait a minute, this is not my plugin :-D

krasa commented 9 years ago

Perhaps you wanted to report it for https://plugins.jetbrains.com/plugin/7179 Then I would suggest updating to 2.2.138.1503

ghost commented 9 years ago

mvnrunner I'm using this Plugin --> Click on the Link --> Arrive here --> Created issue.

Also in EventLog: mvnrunner2

So i'm confused now. Should i uninstall this Plugin and Install MavenHelper instead (which i alredy have)?

krasa commented 9 years ago

I see, the code went through 2 plugins, but the problem really is in MvnRunner which needs to be recompiled for IJ 14, if you disable it, everything will be fine.

shlxue commented 9 years ago

@wuSam Thanks. the issue was fixed. Please update the plugin from IDEA plugin repository.

krasa commented 9 years ago

@ShlXue it wont work for IJ 13 org.jetbrains.idea.maven.project.MavenProjectsManager#getExplicitProfiles returns MavenExplicitProfiles only in IJ 14, you need either a new plugin branch or use some reflection

krasa commented 9 years ago

IJ 13.1.4:

update failed for ActionGroup: Test file (Run current File with Maven)[Test file]: org.jetbrains.idea.maven.project.MavenProjectsManager.getExplicitProfiles()Lorg/jetbrains/idea/maven/model/MavenExplicitProfiles;
java.lang.NoSuchMethodError: org.jetbrains.idea.maven.project.MavenProjectsManager.getExplicitProfiles()Lorg/jetbrains/idea/maven/model/MavenExplicitProfiles;
    at com.lightd.ideap.maven.execution.MavenModuleConfigurationProducer.createMavenParameters(MavenModuleConfigurationProducer.java:78)
    at com.lightd.ideap.maven.execution.MavenModuleConfigurationProducer.setupConfigurationFromContext(MavenModuleConfigurationProducer.java:53)
    at com.lightd.ideap.maven.execution.MavenModuleConfigurationProducer.setupConfigurationFromContext(MavenModuleConfigurationProducer.java:27)
    at com.intellij.execution.actions.RunConfigurationProducer.createConfigurationFromContext(RunConfigurationProducer.java:73)
    at com.intellij.execution.actions.RunConfigurationProducer.findOrCreateConfigurationFromContext(RunConfigurationProducer.java:139)
    at com.intellij.execution.actions.PreferredProducerFind.getConfigurationsFromContext(PreferredProducerFind.java:106)
    at com.intellij.execution.actions.PreferredProducerFind.findConfigurationFromContext(PreferredProducerFind.java:131)
    at com.intellij.execution.actions.PreferredProducerFind.createConfiguration(PreferredProducerFind.java:43)
    at com.intellij.execution.actions.ConfigurationContext.createConfiguration(ConfigurationContext.java:119)
    at com.intellij.execution.actions.ConfigurationContext.getConfiguration(ConfigurationContext.java:112)
    at krasa.mavenrun.action.RunTestFileAction.update(RunTestFileAction.java:91)
    at com.intellij.openapi.actionSystem.ex.ActionUtil.performDumbAwareUpdate(ActionUtil.java:113)
    at com.intellij.openapi.actionSystem.impl.Utils.doUpdate(Utils.java:187)
    at com.intellij.openapi.actionSystem.impl.Utils.updateGroupChild(Utils.java:264)
    at com.intellij.openapi.actionSystem.impl.Utils.hasChildrenWithState(Utils.java:238)
    at com.intellij.openapi.actionSystem.impl.Utils.hasVisibleChildren(Utils.java:204)
    at com.intellij.openapi.actionSystem.impl.Utils.expandActionGroup(Utils.java:152)
    at com.intellij.openapi.actionSystem.impl.Utils.expandActionGroup(Utils.java:163)
    at com.intellij.openapi.actionSystem.impl.Utils.expandActionGroup(Utils.java:85)
    at com.intellij.openapi.actionSystem.impl.Utils.fillMenu(Utils.java:279)
    at com.intellij.openapi.actionSystem.impl.ActionPopupMenuImpl$MyMenu.show(ActionPopupMenuImpl.java:96)
    at com.intellij.ide.ui.customization.CustomizationUtil$3.invokePopup(CustomizationUtil.java:284)
    at com.intellij.ui.PopupHandler.mouseReleased(PopupHandler.java:55)
    at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:290)
    at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:289)
    at java.awt.Component.processMouseEvent(Component.java:6516)
    at javax.swing.JComponent.processMouseEvent(JComponent.java:3320)
    at com.intellij.ui.treeStructure.Tree.processMouseEvent(Tree.java:418)
    at com.intellij.ide.dnd.aware.DnDAwareTree.processMouseEvent(DnDAwareTree.java:52)
    at java.awt.Component.processEvent(Component.java:6281)
    at java.awt.Container.processEvent(Container.java:2229)
    at java.awt.Component.dispatchEventImpl(Component.java:4872)
    at java.awt.Container.dispatchEventImpl(Container.java:2287)
    at java.awt.Component.dispatchEvent(Component.java:4698)
    at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4832)
    at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4492)
    at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4422)
    at java.awt.Container.dispatchEventImpl(Container.java:2273)
    at java.awt.Window.dispatchEventImpl(Window.java:2719)
    at java.awt.Component.dispatchEvent(Component.java:4698)
    at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:735)
    at java.awt.EventQueue.access$200(EventQueue.java:103)
    at java.awt.EventQueue$3.run(EventQueue.java:694)
    at java.awt.EventQueue$3.run(EventQueue.java:692)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
    at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:87)
    at java.awt.EventQueue$4.run(EventQueue.java:708)
    at java.awt.EventQueue$4.run(EventQueue.java:706)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:705)
    at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:697)
    at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:520)
    at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:335)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:242)
    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:161)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:150)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:146)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:138)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:91)
shlxue commented 9 years ago

Yes. Version 0.4 don't work on 13.x, I will create a branch for IntelliJ 13.x.

shlxue commented 9 years ago

@wuSam @krasa The plugin was updated. Now can work on IDEA version 12, 13 and 14. Please update.

krasa commented 9 years ago

protip: make versions like this 0.4.2.123 0.4.2.139 0.4.2.133 0.4.2.135

so that people can update a plugin when they update IDE

shlxue commented 9 years ago

@krasa Yes, you are right. Update version: 0.4.2.

Now, version info:

Version Slice Build Until Build IDEA Version
0.4.2 139 14
0.4.2 135 139 13.1
0.4.2 133 135 13
0.4.2 123 133 12.0.4
krasa commented 9 years ago

I meant that the version number should be "0.4.2" but "0.4.2.xxx"

shlxue commented 9 years ago

@krasa You meant that using version style 0.4.2.xxx(123,133,135...), people can auto update the plugin when they update IDEA.

I don't think so. Update IDEA always a new install, then people only can import some settings from a previous version, and can't import custom plugins, we must be reinstall from JetBrains plugin repository. Maybe don't append the suffix, if it's true. What do you think?

krasa commented 9 years ago

You can also install new IntelliJ and change idea.properties to point into the existing .IntelliJIdeaXX folder, that way you do not need to reinstall or import anything. The downside is that you cannot update a plugin if it has the same version. I do not know how many people use this way...

shlxue commented 9 years ago

@krasa It's better if platform can check the plugin update. The pull request: optimize plugin version checking when update intellij platform version for IntelliJ platform.