gluonhq / ide-plugins

Gluon integration with Java IDEs
BSD 3-Clause "New" or "Revised" License
20 stars 9 forks source link

Eclipse plugin fails with Buildship 3.0 #19

Open jperedadnr opened 5 years ago

jperedadnr commented 5 years ago

Buildship 3.0 was been released with Eclipse 2018-12 and they have move guava from [15-16) to 21.

The plugin fails to install:

Cannot complete the install because one or more required items could not 
be found. 
  Software being installed: Gluon Plug-in for Eclipse 
2.6.0.v20180424-0818 (com.gluonhq.eclipse.feature.group 
2.6.0.v20180424-0818) 
  Missing requirement: Gluon Plug-in for Eclipse 2.6.0.v20180424-0818 
(com.gluonhq.eclipse.plugin 2.6.0.v20180424-0818) requires 'osgi.bundle; 
com.google.guava [15.0.0,16.0.0)' but it could not be found 
  Cannot satisfy dependency: 
    From: Gluon Plug-in for Eclipse 2.6.0.v20180424-0818 
(com.gluonhq.eclipse.feature.group 2.6.0.v20180424-0818) 
    To: org.eclipse.equinox.p2.iu; com.gluonhq.eclipse.plugin 
[2.6.0.v20180424-0818,2.6.0.v20180424-0818]
jperedadnr commented 5 years ago

Submitted PR to fix this issue, waiting for review

jperedadnr commented 5 years ago

How to test the plugin:

alanwhite commented 5 years ago

Failing to build on macOS, stack trace last below, also tried to see if the referenced eclipse installed in the sdk would run on it's own, started but hung with following errors, hope that's a clue!

➜ MacOS ./eclipse WARNING: An illegal reflective access operation has occurred WARNING: Illegal reflective access by org.eclipse.osgi.storage.FrameworkExtensionInstaller (file:/Users/alanwhite/.tooling/eclipse/targetPlatforms/eclipse-sdk/eclipse/plugins/org.eclipse.osgi_3.10.2.v20150203-1939.jar) to method java.net.URLClassLoader.addURL(java.net.URL) WARNING: Please consider reporting this to the maintainers of org.eclipse.osgi.storage.FrameworkExtensionInstaller WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations WARNING: All illegal access operations will be denied in a future release

➜ eclipse git:(master) ✗ ./gradlew build --stacktrace

FAILURE: Build failed with an exception.

alanwhite commented 5 years ago

More debug, sorry I didn't do this before posting above, this is deffo above my paygrade now :)

!ENTRY

org.eclipse.core.net 1 0 2019-02-01 22:46:51.702

!MESSAGE System property http.nonProxyHosts has been set to local|.local|169.254/16|.169.254/16 by an external source. This value will be overwritten using the values from the preferences

The installable unit org.eclipse.m2e.feature.feature.group/1.8.0.20160921-2002 has not been found.

Application failed, log file location: /Users/alanwhite/.tooling/eclipse/targetPlatforms/eclipse-sdk/eclipse/configuration/1549061209055.log

Installation failed.

!ENTRY org.eclipse.equinox.p2.director.app 4 0 2019-02-01 22:47:25.933 !MESSAGE The installable unit org.eclipse.m2e.feature.feature.group/1.8.0.20160921-2002 has not been found.

:assembleTargetPlatform (Thread[Task worker for ':',5,main]) completed. Took 38.704 secs.

FAILURE: Build failed with an exception.

jperedadnr commented 5 years ago

I'm uploading the repository with the plugin, so you don't need to build it:

repository.zip

You can just download it and unzip it, then install it from Eclipse 2018-12 as I explained before.

You will probably need to update Eclipse to Buildship to 3.0.1 before. So go to Install new Software and add this url: http://download.eclipse.org/buildship/updates/e49/releases/3.x, and install that version. Then install the plugin.

alanwhite commented 5 years ago

All up and running thanks, the generated app fails to run, I'll go figure that bit

:GluonSingleApp:compileJava UP-TO-DATE :GluonSingleApp:processResources UP-TO-DATE :GluonSingleApp:classes UP-TO-DATE :GluonSingleApp:compileDesktopJava NO-SOURCE :GluonSingleApp:processDesktopResources NO-SOURCE :GluonSingleApp:desktopClasses UP-TO-DATE :GluonSingleApp:runException in Application start method Exception in thread "main" java.lang.reflect.InvocationTargetException at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

jperedadnr commented 5 years ago

Cool, good to know. Be aware that the plugin still runs over Java 8.

alanwhite commented 5 years ago

just figured that out! issue was I was running at 9 on this installation. All working now end to end, thanks for the assist.

nlisker commented 5 years ago

I'm using Eclipse 2018-09 (4.9) with Buildship 3.0.2 and Gluon Plug-in for Eclipse 2.6.0. Installation was fine, but when trying to create a new VM project with the wizard I get:

image

is this related or should I open a new issue?

jperedadnr commented 5 years ago

@nlisker Plugin 2.6.0 requires Buildship 2.x, I'm not sure if that could be the issue.

Can you try to upgrade the plugin from the zip I posted?

nlisker commented 5 years ago

@jperedadnr That fixes the issue! Thanks!

By the way, the default Gluon VM sample project still uses Java 8, so it will not compile after creation, in case it's something you will want to look at at some point.

gapustwo commented 5 years ago

Worked for me on 2019-03. Just had to install e(fx)clipse 3.5 plus the buildship update you mentioned. Thanks!

nlisker commented 5 years ago

Is the Buildship 3 compatible version planned to be available in the update site?

Also, is e(fx)clipse 3.5 a dependency?

rmsma1-iscteiul commented 4 years ago

image

Can't start a project... I have been like 5 hours trying to make this work... I want to try gluon out but idk how to fix this, can someone give me some guide lines

mortensen commented 4 years ago

So you have to install some "buildship" stuff, then download a repository, then install efxclipse and use an old Java 8 version? I don't wanna be ungrateful, but @jperedadnr are there actual plans for a newer plugin version release that will run out of marketplace out of the box? Regards