Can't build my IDE plugin for IntelliJ IDEA 2019.2

Answered

Hi. I have some problems with building my plugin for new version of IDEA (2019.2)

Firstly, my runIde task fails with the following exception:

13:16:16.420 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] 
13:16:16.420 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] FAILURE: Build failed with an exception.
13:16:16.420 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]
13:16:16.420 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] * What went wrong:
13:16:16.420 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] Execution failed for task ':runIde'.
13:16:16.420 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] > Unable to expand TAR 'C:\Users\<username>\.gradle\caches\modules-2\files-2.1\com.jetbrains\jbre\jbr-11_0_3-windows-x64-b304.10.tar.gz'
13:16:16.421 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] The tar might be corrupted or it is compressed in an unexpected way.
13:16:16.421 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] By default the tar tree tries to guess the compression based on the file extension.
13:16:16.421 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] If you need to specify the compression explicitly please refer to the DSL reference.

I fixed this issue by changing jbrVersion for runIde in my build.gradle:

runIde {
    jbrVersion = '8u202b1483.24'
}

P.S.: Don't think that it is perfect solution but it works in this case.

Now i can succesfully execute runIde task, but still cannot build plugin because of same exception on buildSearchableOptions step. I did the same thing on this step like with runIde:

buildSearchableOptions {
    jbrVersion = '8u202b1483.24'
}

and now i get the following:

13:28:55.606 [QUIET] [system.out] Starting searchable options index builder
13:28:56.474 [QUIET] [system.out] #
13:28:56.474 [QUIET] [system.out] # A fatal error has been detected by the Java Runtime Environment:
13:28:56.474 [QUIET] [system.out] #
13:28:56.474 [QUIET] [system.out] # EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x0000000068224d9b, pid=74024, tid=0x000000000000d5b0
13:28:56.474 [QUIET] [system.out] #
13:28:56.474 [QUIET] [system.out] # JRE version: OpenJDK Runtime Environment (8.0_202-b24) (build 1.8.0_202-release-1483-b24)
13:28:56.474 [QUIET] [system.out] # Java VM: OpenJDK 64-Bit Server VM (25.202-b24 mixed mode windows-amd64 compressed oops)
13:28:56.475 [QUIET] [system.out] # Problematic frame:
13:28:56.475 [QUIET] [system.out] # V [jvm.dll+0x124d9b]
13:28:56.484 [QUIET] [system.out] #
13:28:56.484 [QUIET] [system.out] # Failed to write core dump. Minidumps are not enabled by default on client versions of Windows
13:28:56.484 [QUIET] [system.out] #
13:28:56.485 [QUIET] [system.out] # An error report file with more information is saved as:
13:28:56.485 [QUIET] [system.out] # C:\Users\<username>\.gradle\caches\modules-2\files-2.1\com.jetbrains.intellij.idea\ideaIC\2019.2\b6afbf1111dae2b3e18581cd0b89bbfb063db9d5\ideaIC-2019.2\bin\hs_err_pid74024.log
13:28:56.535 [QUIET] [system.out] #
13:28:56.535 [QUIET] [system.out] # If you would like to submit a bug report, please visit:
13:28:56.535 [QUIET] [system.out] # http://bugreport.java.com/bugreport/crash.jsp
13:28:56.536 [QUIET] [system.out] #

Here is part of my build.gradle:

plugins {
id 'org.jetbrains.intellij' version '0.4.9'
id 'org.jetbrains.kotlin.jvm' version '1.3.41'
}
intellij {
version '2019.2'
plugins 'org.jetbrains.kotlin:1.3.41-release-IJ2019.2-1'
intellij.updateSinceUntilBuild false
plugins 'java'
buildSearchableOptions {
jbrVersion = '8u202b1483.24'
}
}

Call stack from error report file:

Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
j sun.awt.windows.ThemeReader.getThemeMargins(JIII)Ljava/awt/Insets;+0
j sun.awt.windows.ThemeReader.getThemeMargins(Ljava/lang/String;III)Ljava/awt/Insets;+18
j com.sun.java.swing.plaf.windows.XPStyle.getMargin(Ljava/awt/Component;Lcom/sun/java/swing/plaf/windows/TMSchema$Part;Lcom/sun/java/swing/plaf/windows/TMSchema$State;Lcom/sun/java/swing/plaf/windows/TMSchema$Prop;)Ljava/awt/Insets;+19
j com.sun.java.swing.plaf.windows.XPStyle.getBorder(Ljava/awt/Component;Lcom/sun/java/swing/plaf/windows/TMSchema$Part;)Ljavax/swing/border/Border;+169
j com.sun.java.swing.plaf.windows.WindowsLookAndFeel$XPBorderValue.getXPValue(Ljavax/swing/UIDefaults;)Ljava/lang/Object;+17
j com.sun.java.swing.plaf.windows.WindowsLookAndFeel$XPValue.createValue(Ljavax/swing/UIDefaults;)Ljava/lang/Object;+10
j javax.swing.UIDefaults.getFromHashtable(Ljava/lang/Object;)Ljava/lang/Object;+231
j javax.swing.UIDefaults.get(Ljava/lang/Object;)Ljava/lang/Object;+2
j javax.swing.MultiUIDefaults.get(Ljava/lang/Object;)Ljava/lang/Object;+45
j javax.swing.UIDefaults.getBorder(Ljava/lang/Object;)Ljavax/swing/border/Border;+2
j javax.swing.UIManager.getBorder(Ljava/lang/Object;)Ljavax/swing/border/Border;+4
j javax.swing.LookAndFeel.installBorder(Ljavax/swing/JComponent;Ljava/lang/String;)V+18
j javax.swing.plaf.basic.BasicButtonUI.installDefaults(Ljavax/swing/AbstractButton;)V+183
j com.sun.java.swing.plaf.windows.WindowsButtonUI.installDefaults(Ljavax/swing/AbstractButton;)V+2
j javax.swing.plaf.basic.BasicButtonUI.installUI(Ljavax/swing/JComponent;)V+5
j javax.swing.JComponent.setUI(Ljavax/swing/plaf/ComponentUI;)V+39
j javax.swing.AbstractButton.setUI(Ljavax/swing/plaf/ButtonUI;)V+2
j javax.swing.JButton.updateUI()V+8
j javax.swing.AbstractButton.init(Ljava/lang/String;Ljavax/swing/Icon;)V+19
j javax.swing.JButton.<init>(Ljava/lang/String;Ljavax/swing/Icon;)V+18
j javax.swing.JButton.<init>()V+3
j com.intellij.debugger.settings.CaptureConfigurable.$$$setupUI$$$()V+130
j com.intellij.debugger.settings.CaptureConfigurable.<init>(Lcom/intellij/openapi/project/Project;)V+10
v ~StubRoutines::call_stub
J 2148 sun.reflect.NativeConstructorAccessorImpl.newInstance0(Ljava/lang/reflect/Constructor;[Ljava/lang/Object;)Ljava/lang/Object; (0 bytes) @ 0x0000000004062aa6 [0x0000000004062a40+0x66]
J 2155 C1 sun.reflect.NativeConstructorAccessorImpl.newInstance([Ljava/lang/Object;)Ljava/lang/Object; (89 bytes) @ 0x000000000405dfd4 [0x000000000405cf80+0x1054]
J 2305 C1 sun.reflect.DelegatingConstructorAccessorImpl.newInstance([Ljava/lang/Object;)Ljava/lang/Object; (9 bytes) @ 0x00000000040f9f44 [0x00000000040f9e40+0x104]
J 2285 C1 java.lang.reflect.Constructor.newInstance([Ljava/lang/Object;)Ljava/lang/Object; (87 bytes) @ 0x00000000040eac4c [0x00000000040ea780+0x4cc]
j org.picocontainer.defaults.InstantiatingComponentAdapter.newInstance(Ljava/lang/reflect/Constructor;[Ljava/lang/Object;)Ljava/lang/Object;+14
j com.intellij.util.pico.CachingConstructorInjectionComponentAdapter.doGetComponentInstance(Lorg/picocontainer/PicoContainer;)Ljava/lang/Object;+37
j com.intellij.util.pico.CachingConstructorInjectionComponentAdapter.instantiateGuarded(Lorg/picocontainer/PicoContainer;Ljava/lang/Class;)Ljava/lang/Object;+72
j com.intellij.util.pico.CachingConstructorInjectionComponentAdapter.getComponentInstance(Lorg/picocontainer/PicoContainer;)Ljava/lang/Object;+25
j com.intellij.openapi.extensions.AbstractExtensionPointBean.instantiate(Ljava/lang/Class;Lorg/picocontainer/PicoContainer;Z)Ljava/lang/Object;+35
j com.intellij.openapi.extensions.AbstractExtensionPointBean.instantiate(Ljava/lang/Class;Lorg/picocontainer/PicoContainer;)Ljava/lang/Object;+21
j com.intellij.openapi.options.ConfigurableEP$ClassProducer.createElement()Ljava/lang/Object;+8
j com.intellij.openapi.options.ConfigurableEP.createConfigurable()Lcom/intellij/openapi/options/UnnamedConfigurable;+19
j com.intellij.openapi.options.ex.ConfigurableWrapper.createConfigurable(Lcom/intellij/openapi/options/ConfigurableEP;Z)Lcom/intellij/openapi/options/UnnamedConfigurable;+13
j com.intellij.openapi.options.ex.ConfigurableWrapper.getConfigurable()Lcom/intellij/openapi/options/UnnamedConfigurable;+13
j com.intellij.openapi.options.ex.ConfigurableWrapper.cast(Ljava/lang/Class;Lcom/intellij/openapi/options/UnnamedConfigurable;)Ljava/lang/Object;+58
j com.intellij.openapi.options.ex.ConfigurableWrapper.getId()Ljava/lang/String;+42
j com.intellij.openapi.options.ex.ConfigurableExtensionPointUtil.groupConfigurables(Ljava/util/List;)Ljava/util/Map;+69
j com.intellij.openapi.options.ex.ConfigurableExtensionPointUtil.getConfigurableGroup(Ljava/util/List;Lcom/intellij/openapi/project/Project;)Lcom/intellij/openapi/options/ConfigurableGroup;+10
j com.intellij.openapi.options.ex.ConfigurableExtensionPointUtil.getConfigurableGroup(Lcom/intellij/openapi/project/Project;Z)Lcom/intellij/openapi/options/ConfigurableGroup;+21
j com.intellij.ide.actions.ShowSettingsUtilImpl.getConfigurables(Lcom/intellij/openapi/project/Project;Z)Ljava/util/List;+2
j com.intellij.ide.ui.search.SearchUtil.processProjectConfigurables(Lcom/intellij/openapi/project/Project;Ljava/util/Map;)V+2
j com.intellij.ide.ui.search.TraverseUIStarter.startup(Ljava/lang/String;Z)V+76
j com.intellij.ide.ui.search.TraverseUIStarter.main([Ljava/lang/String;)V+16
j com.intellij.idea.IdeaApplication.lambda$null$3(Lcom/intellij/openapi/application/ApplicationStarter;[Ljava/lang/String;)V+2
j com.intellij.idea.IdeaApplication$$Lambda$289.run()V+8
j com.intellij.openapi.application.TransactionGuardImpl.performUserActivity(Ljava/lang/Runnable;)V+15
j com.intellij.idea.IdeaApplication.lambda$executeInitAppInEdt$5(Lcom/intellij/diagnostic/Activity;Lcom/intellij/diagnostic/Activity;Ljava/util/List;Lcom/intellij/openapi/application/impl/ApplicationImpl;ZLcom/intellij/openapi/application/ApplicationStarter;[Ljava/lang/String;)V+117
j com.intellij.idea.IdeaApplication$$Lambda$118.run()V+28
j java.awt.event.InvocationEvent.dispatch()V+47
j java.awt.EventQueue.dispatchEventImpl(Ljava/awt/AWTEvent;Ljava/lang/Object;)V+21
j java.awt.EventQueue.access$500(Ljava/awt/EventQueue;Ljava/awt/AWTEvent;Ljava/lang/Object;)V+3
j java.awt.EventQueue$3.run()Ljava/lang/Void;+32
j java.awt.EventQueue$3.run()Ljava/lang/Object;+1
v ~StubRoutines::call_stub
j java.security.AccessController.doPrivileged(Ljava/security/PrivilegedAction;Ljava/security/AccessControlContext;)Ljava/lang/Object;+0
j java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Ljava/security/PrivilegedAction;Ljava/security/AccessControlContext;Ljava/security/AccessControlContext;)Ljava/lang/Object;+18
j java.awt.EventQueue.dispatchEvent(Ljava/awt/AWTEvent;)V+46
j com.intellij.ide.IdeEventQueue.dispatchEvent(Ljava/awt/AWTEvent;)V+156
j java.awt.EventDispatchThread.pumpOneEventForFilters(I)V+140
j java.awt.EventDispatchThread.pumpEventsForFilter(ILjava/awt/Conditional;Ljava/awt/EventFilter;)V+35
j java.awt.EventDispatchThread.pumpEventsForHierarchy(ILjava/awt/Conditional;Ljava/awt/Component;)V+11
j java.awt.EventDispatchThread.pumpEvents(ILjava/awt/Conditional;)V+4
j java.awt.EventDispatchThread.pumpEvents(Ljava/awt/Conditional;)V+3
j java.awt.EventDispatchThread.run()V+9
v ~StubRoutines::call_stub

Please help. Thank you.

(Full report file contains jvm dump, i can send it if it helps)

12 comments
Comment actions Permalink

Hello,

Is it possible to build project from command line?

0
Comment actions Permalink

Nothing changes, still same errors.

0
Comment actions Permalink

I have sort of the same issue with building IDEA-CE from source. Doesn't work with 2019.1.3, also not with 2019.2. Source code is at idea/192.5728.98. There is a referencing warning with SLF4J (library found twice in the classpath due to source inclusion in maven 3.6), I could work around this, but boy, is that a craptastic interface, see below. Anyway. Build works (with a few tweeks for some android test code acting up), you could even start the application, but the ant build always craps out at this point:

[java] Starting searchable options index builder

... and then coredump (or better not coredump, only crash with some unintelligible info).

This is a bit troubling. Doesn't anybody do a test build of the github repository?

Other interesting observation: Maven has sort of disappeared from the menu, you get no toolbar. If you search and issue a maven goal directly, nothing happens at all. This is true with 2019.2, 192.5728.98 as shipped, and also with the build from source.

 

0
Comment actions Permalink
> 13:16:16.420 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] > Unable to expand TAR 'C:\Users\<username>\.gradle\caches\modules-2\files-2.1\com.jetbrains\jbre\jbr-11_0_3-windows-x64-b304.10.tar.gz'

@Shchavelevnikita, try to remove this file, so it will be redownloaded.

@Jens, I'm sorry, I don't understand how it's related. Please file a bug report at https://youtrack.jetbrains.com with a detailed description of the problem you faced.

0
Comment actions Permalink

First thing i tried was to remove whole com.jetbrains folder, so it's not a problem with this file

0
Comment actions Permalink

Can you untar it manually? Is it corrupted?

 

0
Comment actions Permalink

File is ok, I tried to unpack it manually and got same error as with switched jbrVersion.

0
Comment actions Permalink

> File is ok, I tried to unpack it manually and got same error as with switched jbrVersion.

I didn't get it. It's ok but still cannot be unpacked? What do you mean?
 
Try to download it manually. Is it still cannot be unpacked?
 
0
Comment actions Permalink

No, i unpacked it successfully and got error while trying to build plugin.

0
Comment actions Permalink

If it still can help, i will try to download file manually from your link tomorrow

0
Comment actions Permalink

Probably related, though? Crash on buildSearchableOptions{}? I will file the bug report.

0
Comment actions Permalink

Yes, crash on buildSearchableOptions step

0

Please sign in to leave a comment.