Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lsp4j-build-gradle launch configuration failing with provided jre in Eclipse 2020-12 (jre 15) #486

Open
apupier opened this issue Dec 29, 2020 · 3 comments

Comments

@apupier
Copy link
Contributor

apupier commented Dec 29, 2020

Using:
Eclipse IDE for Eclipse Committers (includes Incubating components)

Version: 2020-12 (4.18.0)
Build id: 20201210-1552

with extra software:

  • Xtend Xtend IDE 2.24.0.v20201130-1016 org.eclipse.xtend.sdk.feature.group Eclipse Xtend
  • Buildship: Eclipse Plug-ins for Gradle 3.1.4.v20200326-1743 org.eclipse.buildship.feature.group Eclipse Buildship
Working Directory: /home/apupier/git/lsp4j
Gradle user home: /home/apupier/.gradle
Gradle Distribution: Gradle wrapper from target build
Gradle Version: 5.5
Java Home: /home/apupier/install/eclipse-committers-2019-06-R-linux-gtk-x86_64/eclipse/plugins/org.eclipse.justj.openjdk.hotspot.jre.full.linux.x86_64_15.0.1.v20201027-0507/jre
JVM Arguments: None
Program Arguments: None
Build Scans Enabled: false
Offline Mode Enabled: false
Gradle Tasks: eclipse assemble


FAILURE: Build failed with an exception.

* What went wrong:
Could not open cp_init remapped class cache for 6a5krabdzij62jglcll542e66 (/home/apupier/.gradle/caches/5.5/scripts-remapped/eclipsePlugin_4akdj3taovy3jm28f2d550zlb/6a5krabdzij62jglcll542e66/cp_init74e694b976d6abaa826c8abac43e9de8).
> Could not open cp_init generic class cache for initialization script '/home/apupier/ws/lsp4j/.metadata/.plugins/org.eclipse.buildship.core/init.d/eclipsePlugin.gradle' (/home/apupier/.gradle/caches/5.5/scripts/6a5krabdzij62jglcll542e66/cp_init/cp_init74e694b976d6abaa826c8abac43e9de8).
   > Could not initialize class org.codehaus.groovy.classgen.Verifier

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

I think, the gradle wrapper needs to be updated to latest version of gradle (6.7.1) but then I have another error;

Working Directory: /home/apupier/git/lsp4j
Gradle user home: /home/apupier/.gradle
Gradle Distribution: Gradle wrapper from target build
Gradle Version: 6.7.1
Java Home: /home/apupier/install/eclipse-committers-2019-06-R-linux-gtk-x86_64/eclipse/plugins/org.eclipse.justj.openjdk.hotspot.jre.full.linux.x86_64_15.0.1.v20201027-0507/jre
JVM Arguments: None
Program Arguments: None
Build Scans Enabled: false
Offline Mode Enabled: false
Gradle Tasks: eclipse assemble


FAILURE: Build failed with an exception.

* Where:
Script '/home/apupier/git/lsp4j/gradle/manifest-gen.gradle' line: 13

* What went wrong:
A problem occurred evaluating script.
> Plugin with id 'osgi' not found.

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/6.7.1/userguide/command_line_interface.html#sec:command_line_warnings

BUILD FAILED in 9s

workaround:

  • specify JAVA_HOME pointing to JDK 8 in Run configuration -> Gradle Task -> lsp4j-build-gradle -> Project Settings -> Override project Settings -> Advanced Options -> Java home
@apupier
Copy link
Contributor Author

apupier commented Dec 29, 2020

ok, seems that the upgrade requires soem change for osgi bundle: https://github.com/bndtools/bnd/blob/master/biz.aQute.bnd.gradle/README.md#replacing-use-of-gradles-deprecated-osgi-plugin looking

@apupier
Copy link
Contributor Author

apupier commented Dec 29, 2020

here is a failed attempt to use the new osgi plugin for gradle: https://github.com/apupier/lsp4j/tree/486-useNewerGradleVersion

current problem is:

2020-12-29T16:20:16.302+0100 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] 
2020-12-29T16:20:16.302+0100 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] FAILURE: Build failed with an exception.
2020-12-29T16:20:16.302+0100 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] 
2020-12-29T16:20:16.302+0100 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] * Where:
2020-12-29T16:20:16.302+0100 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] Script '/home/apupier/git/lsp4j/gradle/manifest-gen.gradle' line: 14
2020-12-29T16:20:16.302+0100 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] 
2020-12-29T16:20:16.302+0100 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] * What went wrong:
2020-12-29T16:20:16.303+0100 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] A problem occurred evaluating script.
2020-12-29T16:20:16.303+0100 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] > Plugin with id 'biz.aQute.bnd.builder' not found.
2020-12-29T16:20:16.303+0100 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] 
2020-12-29T16:20:16.303+0100 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] * Try:
2020-12-29T16:20:16.303+0100 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] Run with --stacktrace option to get the stack trace.  Run with --scan to get full insights.
2020-12-29T16:20:16.303+0100 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] 
2020-12-29T16:20:16.303+0100 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] * Get more help at https://help.gradle.org

@apupier apupier changed the title lsp4j-build-gradle launch configurationfailing with provided jre in Eclipse 2020-12 (jre 15) lsp4j-build-gradle launch configuration failing with provided jre in Eclipse 2020-12 (jre 15) Dec 29, 2020
@jonahgraham
Copy link
Contributor

workaround:

  • specify JAVA_HOME pointing to JDK 8 in Run configuration -> Gradle Task -> lsp4j-build-gradle -> Project Settings -> Override project Settings -> Advanced Options -> Java home

Thank you for providing a workaround.

I think the upgrade to newer Gradle (6.x vs 5.x) is a bigger job. I appreciate you having a look at it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants