Eclipse won't switch workspace - eclipse

Whenever I switch workspace on eclipse, I get the error:
An internal error occurred during: "Initializing Java Tooling".
Duplicate field name&signature in class file org/eclipse/jdt/internal/compiler/ast/ASTNode
If I restart Eclipse, it then loads the new workspace correctly. Any ideas how I go about fixing this?
I'm using Eclipse Kepler on Windows 7

Yup, whoops, lombok bug. Sorry. It's been fixed; the next lombok version (looks like that'll be 1.14) will no longer have this issue. Until then, the edge release can be used if this is really cramping your workspace-switchin' style :)
http://projectlombok.org/download-edge.html

Install the latest version of projectlombok.

I had the same issue. After updating Gradle and anything else that I had installed in Eclipse, it still wouldn't work. For me it actually wouldn't be fixed by restarting Eclipse, as far as I could tell. I managed to fix it by downloading the latest release of Eclipse and extracting it over my current installation. Don't know if that'll work for you or not.

Related

Eclipse Mars 1.0 Build Path Missing From Properties Menu

I have just reinstalled my OS and made a clean install of Eclipse.
I want to import my previous projects made on a previous version of Eclipse and that is no problem. However when I try to run it then it says: "The selection cannot be run on any server".
I read around I need to go into Properties => Build Path and do something there.
Only problem is my Properties menu does not have a Build Path option. I have searched around Eclipse for a long time now to find Build Path but stil no luck.
Does anyone now where og why my Build Path is no where to be found?
By Chance i found the solution myself.
I originally installed the Eclipse Php Mars version of Eclipse which i still can't get to work. But install the Eclipse Jee Mars (Java EE IDE) version instead solves the problem.
First time you run the code though you might have to run it through the main menu in the top and not by the convenient Run icon botton.
I have no clue why this is but now i can continue my work.

Upgrade Eclipse without opening it

I have Eclipse Juno with Java EE, PHP, C++ and PyDev in it and it was working perfectly under Ubuntu 12.04 and later under 14.04.
Yet, when I upgraded my OS to Ubuntu 14.10, Eclipse doesn't work anymore, whenever I try to open it, it shuts down immediately.
I want to upgrade it to Luna but it doesn't give me the chance to launch the upgrade, I have an idea I have and wish to hear your advice on whether it is right or wrong.
What I'd like to do is to download Luna and extract it over the older version.
Will this work? Or will it make it even worse?
Is there anyone who tired it before?
You may even download Luna, and extract it to a different folder (not necessary on top of the older version).
Afterwards, launch Luna and try to load your previous workspace(s). You might want to backup your workspaces folder, before letting Luna attempt and load from there.
Updating the eclipse through the command line is safer. Try it using eclipse site
and also refer to this answer
I find solution here https://bugs.eclipse.org/bugs/show_bug.cgi?id=440660#c20 on comment 20
This seems to be a bug in GTK according to https://bugs.launchpad.net/ubuntu/+source/gtk2-engines-oxygen/+bug/1242801
(there a similar problem for Meld was reported).
Another workaround mentioned there is
For oxygen, edit the normally already existing file "/usr/share/themes/oxygen-gtk/gtk-2.0/gtkrc" and change
GtkComboBox::appears-as-list = 1
into
GtkComboBox::appears-as-list = 0
This workaround is working for me.

Eclipse Luna crashes on new project in Ubuntu

I'm having some trouble getting Eclipse Luna to work. I downloaded the tar.gz from the eclipse site and I downloaded the tar.gz for the Java JDK. I extracted everything and Eclipse opens properly, but when I try to make a new project, it crashes on me. In the terminal I ran java -version and it tells me I have version 1.8.0_25 so I don't think I have an issue with java. Now, this happens if I try to make any kind of project. Eclipse opens the wizard for creating a new project of a particular type and then the whole application crashes. When I started doing this, I installed it under the KDE desktop. When Eclipse crashes, I get the message java: /build/buildd/gtk2-engines-oxygen-1.4.5/src/animations/oxygencomboboxdata.cpp:87‌​: void Oxygen::ComboBoxData::setButton(GtkWidget*): Assertion '!_button._widget' failed. So, I decided to install the xfce desktop to get around it, since oxygen is a KDE theme. I uninstalled eclipse and reinstalled it under xfce and I have the same behavior and the same errors. When I run eclipse from the command line, I get this exception on startup:
java.lang.ClassCastException: org.eclipse.osgi.internal.framework.EquinoxConfiguration$1 cannot be cast to java.lang.String
at org.eclipse.m2e.logback.configuration.LogHelper.logJavaProperties(LogHelper.java:26)
at org.eclipse.m2e.logback.configuration.LogPlugin.loadConfiguration(LogPlugin.java:189)
at org.eclipse.m2e.logback.configuration.LogPlugin.configureLogback(LogPlugin.java:144)
at org.eclipse.m2e.logback.configuration.LogPlugin.access$2(LogPlugin.java:107)
at org.eclipse.m2e.logback.configuration.LogPlugin$1.run(LogPlugin.java:62)
at java.util.TimerThread.mainLoop(Timer.java:555)
at java.util.TimerThread.run(Timer.java:505)
Does anyone have any ideas on what else to try?
According to comment 20 in this bug report: https://bugs.eclipse.org/bugs/show_bug.cgi?id=440660#c20
This seems to be a bug in GTK according to
https://bugs.launchpad.net/ubuntu/+source/gtk2-engines-oxygen/+bug/1242801
(there a similar problem for Meld was reported).
Another workaround mentioned there is for Oxygen, edit the normally already existing file
/usr/share/themes/oxygen-gtk/gtk-2.0/gtkrc and change
`GtkComboBox::appears-as-list = 1`
into
`GtkComboBox::appears-as-list = 0`
This workaround is working for me.
I have resolved this issue by installing package gtk2-engines-oxygen built for Ubuntu Vivid Vervet (version 1.4.6):
http://packages.ubuntu.com/vivid/gtk2-engines-oxygen

Eclipse says 'Class not found' even though the classes are available

In Eclipse UI, I got the following problem,
If you see left side, the classes are available. I am able to build using Maven and run it successfully. But this Eclipse error highlighting is really annoying.
I am using Eclipse Indigo SR2 and installed Spring Tool Suite. Please help me on fixing this issue. Thanks.
try importing com.beatle.model.* and see what happens

NullPointerException from Eclipse Compiler

I am receiving the following message from my Eclipse compiler, and my project fails to compile....
Internal compiler error: java.lang.NullPointerException at org.eclipse.jdt.internal.compiler.problem.ProblemReporter.missingTypeInMethod(ProblemReporter.java:5075)
I've tried updating Eclipse, restarting eclipse, closing and opening the project, refreshing, cleaning/rebuilding, etc. I'm out of ideas.
That seems to be the bug 250297, fixed in eclipse 3.4.2. Also fixed in the 3.5 (M4, November 2008, as mentioned in this JDT release notes)
The failure occurs on line (>>>):
public void missingTypeInMethod(MessageSend messageSend, MethodBinding method)
{
List missingTypes = method.collectMissingTypes(null);
>>> TypeBinding missingType = (TypeBinding) missingTypes.get(0);
It would indicate that though we identified a missing type (which we try to complain against), we fail to locate it inside the method signature...
So... if you are using an "older" version of eclipse (like 3.4, or 3.4.1), a good solution is to upgrade (that is, install another fresh version of eclipse, 3.4.2 or 3.5.1), while reusing your same workspace.
The error should then go away.
I had this problem as late as Eclipse Luna (4.4). The only way I found to get rid of it was to upgrade to Eclipse Mars (4.5.0). I don't know if this is relevant to the issue, but I upgraded to java 8 shortly before the problem arose.
HTH.