Created Idea SDK - now get Startup error with plugin
I created an IDEA sdk (in out/deploy) and am trying to run a plugin with it (in IDEA). I get the following error. What might be going wrong?
[ 252] ERROR - ation.impl.ApplicationInfoImpl - Argument 0 for @NotNull parameter of com/intellij/openapi/util/JDOMUtil.loadDocument must not be null
java.lang.IllegalArgumentException: Argument 0 for @NotNull parameter of com/intellij/openapi/util/JDOMUtil.loadDocument must not be null
at com.intellij.openapi.util.JDOMUtil.loadDocument(JDOMUtil.java)
at com.intellij.openapi.application.impl.ApplicationInfoImpl.getShadowInstance(ApplicationInfoImpl.java:287)
at com.intellij.ui.AppUIUtil.getAppIconImages(AppUIUtil.java:50)
at com.intellij.ui.AppUIUtil.updateFrameIcon(AppUIUtil.java:39)
at com.intellij.idea.MainImpl._main(MainImpl.java:80)
at com.intellij.idea.MainImpl.start(MainImpl.java:72)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.intellij.ide.plugins.PluginManager$3.run(PluginManager.java:149)
at java.lang.Thread.run(Thread.java:619)
[ 255] ERROR - ation.impl.ApplicationInfoImpl - JDK: 1.6.0_20
[ 255] ERROR - ation.impl.ApplicationInfoImpl - VM: Java HotSpot(TM) 64-Bit Server VM
[ 255] ERROR - ation.impl.ApplicationInfoImpl - Vendor: Sun Microsystems Inc.
[ 255] ERROR - ation.impl.ApplicationInfoImpl - OS: Linux
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.intellij.ide.plugins.PluginManager$3.run(PluginManager.java:149)
at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.AssertionError
at com.intellij.ide.plugins.PluginManager.initializePlugins(PluginManager.java:200)
at com.intellij.ide.plugins.PluginManager.getPlugins(PluginManager.java:103)
at com.intellij.openapi.application.impl.ApplicationImpl.loadApplicationComponents(ApplicationImpl.java:290)
at com.intellij.openapi.application.impl.ApplicationImpl.<init>(ApplicationImpl.java:193)
at com.intellij.openapi.application.ex.ApplicationManagerEx.createApplication(ApplicationManagerEx.java:35)
at com.intellij.idea.IdeaApplication.<init>(IdeaApplication.java:72)
at com.intellij.idea.MainImpl.startApplication(MainImpl.java:103)
at com.intellij.idea.MainImpl._main(MainImpl.java:99)
at com.intellij.idea.MainImpl.start(MainImpl.java:72)
... 6 more
[ 644] ERROR - llij.ide.plugins.PluginManager - Error while accessing com.intellij.idea.MainImpl.start with arguments: []
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.intellij.ide.plugins.PluginManager$3.run(PluginManager.java:149)
at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.AssertionError
at com.intellij.ide.plugins.PluginManager.initializePlugins(PluginManager.java:200)
at com.intellij.ide.plugins.PluginManager.getPlugins(PluginManager.java:103)
at com.intellij.openapi.application.impl.ApplicationImpl.loadApplicationComponents(ApplicationImpl.java:290)
at com.intellij.openapi.application.impl.ApplicationImpl.<init>(ApplicationImpl.java:193)
at com.intellij.openapi.application.ex.ApplicationManagerEx.createApplication(ApplicationManagerEx.java:35)
at com.intellij.idea.IdeaApplication.<init>(IdeaApplication.java:72)
at com.intellij.idea.MainImpl.startApplication(MainImpl.java:103)
at com.intellij.idea.MainImpl._main(MainImpl.java:99)
at com.intellij.idea.MainImpl.start(MainImpl.java:72)
... 6 more
[ 646] ERROR - llij.ide.plugins.PluginManager - JDK: 1.6.0_20
[ 647] ERROR - llij.ide.plugins.PluginManager - VM: Java HotSpot(TM) 64-Bit Server VM
[ 647] ERROR - llij.ide.plugins.PluginManager - Vendor: Sun Microsystems Inc.
[ 647] ERROR - llij.ide.plugins.PluginManager - OS: Linux
[ 647] ERROR - llij.ide.plugins.PluginManager - Original exception:
java.lang.AssertionError
at com.intellij.ide.plugins.PluginManager.initializePlugins(PluginManager.java:200)
at com.intellij.ide.plugins.PluginManager.getPlugins(PluginManager.java:103)
at com.intellij.openapi.application.impl.ApplicationImpl.loadApplicationComponents(ApplicationImpl.java:290)
at com.intellij.openapi.application.impl.ApplicationImpl.<init>(ApplicationImpl.java:193)
at com.intellij.openapi.application.ex.ApplicationManagerEx.createApplication(ApplicationManagerEx.java:35)
at com.intellij.idea.IdeaApplication.<init>(IdeaApplication.java:72)
at com.intellij.idea.MainImpl.startApplication(MainImpl.java:103)
at com.intellij.idea.MainImpl._main(MainImpl.java:99)
at com.intellij.idea.MainImpl.start(MainImpl.java:72)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.intellij.ide.plugins.PluginManager$3.run(PluginManager.java:149)
at java.lang.Thread.run(Thread.java:619)
请先登录再写评论。
I looked into this further. The first exception
[ 252] ERROR - ation.impl.ApplicationInfoImpl - Argument 0 for @NotNull parameter of com/intellij/openapi/util/JDOMUtil.loadDocument must not be null
occurs because of a problem in getShadowInstance() in ApplicationInfoImpl.java at line 299.
ApplicationInfoImpl.class.getResourceAsStream returns null when called with the argument - /idea/IdeaApplicationInfo.xml
For some reason it can't find IdeaApplicationInfo.xml. I checked and resource.jar which contains this file is added to the sdk path.
Any idea why this is happening?
Also should intellij still be able to start if this file is not found?
thanks
Siddharth
Hello Siddharth,
I don't quite understand what exactly you're trying to do. If you're trying
to debug IDEA and your plugin together, you shouldn't use an IDEA SDK at
all - just add the plugin module to the IDEA project.
--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"
Thanks Dmitry,
That seems a reasonable way to go about it. I did the following steps.
I now get the following error
Wrong jdk type for plugin module 'GooglePlugin'.
Essentially GooglePlugin expects to be built using an IDEA sdk whereas I have just provided a JDK with all the sources needed to build IDEA. Theoretically this should build but I guess the plugin is designed to be compiled using a IDEA sdk...How should I go about this? What am I missing?
regards
Siddharth
Hello Siddharth,
For such a configuration, you need to create a separate .iml file (of type
Java module, rather than Plugin module), and add that to the IDEA project.
--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"
Hi Dmitry,
K... I changed the module to JAVA (from plugin)... How do I actually go about starting IDEA with the plugin enabled. Is there a configuration file somewhere?
While my plugin can compile successfully, I don't get it in the plugin list when IDEA starts
thanks
Siddharth
Hello Siddharth,
Add your module to the dependencies of the 'community-main' module.
--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"