eclipse Oxygen mouse hover not showing error/warnings - java

After upgrading to new eclipse Oxygen (4.7.0), I don't see code warnings or errors when I hover on the highlighted code element.
Also, I can't get variable values in debug mode when hovering on one.
For both cases, javadoc is being show.
I tried to reset hover preferences under Java and general section to its defaults, but it does not fix the problem.
Is there any workaround/fix for this, or as usual, we have to wait for the next eclipse service release?

I'm answering my own question, to help anyone with the same issue.
After reporting this to eclipse Bugzilla, I got a comment about possibility of conflict with an updated plugin. I then checked my newly installed plugins and found the guilty one: ZipEditor v1.1.3.201703012047
Deleting this plugin fixed my issue.
EDIT: It looks like the issue was layered and I had to remove eclipse Class Decompiler 2.9.11.20170710, too.

Related

VScode complains that Java project has no explicit encoding set

I have been using vscode with no problems until recently. Now no errors show up, some variables never change color. And I have a constant error message:
Project ... has no explicit encoding set
I have no idea what I need to do to fix it.
Just a few minutes earlier I was also having the same problem. Here is how I fixed it:
Click on the Gear Icon.
Click on Settings.
Click on Command Palette.
Type Clean java language server workspace.
Hit Restart and Delete.
After reloading is done, the issue will be fixed.
I believe this is a bug caused by v1.5.0 Red Hat's Language Support for Java extension. Nothing I tried fixed it, so the best solution may be to wait for the extension developers to fix it.
You can follow the issue on GitHub https://github.com/redhat-developer/vscode-java/issues/2416
Update 4/21/2022: Looks like it was caused by an upstream issue in the Eclipse JDT Language Server (which is used by the Visual Studio Code Java extension). Check the GitHub link above for details.
Update 5/13/2022: Upstream issue has finally been resolved and merged. Red Hat's Language Support for Java extension no longer has this bug for me as of v1.6.0.
I experienced the same problem after the Language Support for Java by Red Hat extension had been updated to v1.5.0. No code errors were reported and only the message about no explicit encoding was shown in the Problems tab.
I was able to resolve the issue by clicking the "..." next to "Java Projects" in the Explorer view, and selecting "Clean Workspace", then "Restart and delete".
After the application had reloaded, the issue was gone and language server started working as usual.
I have same problems before few minutes ago.
and I solved this problem.
File -> Save Workspace AS -> Choose Your directory -> Save

Eclipse "Apply Checkstyle fixes" or "Quick Fix" does nothing when trying to fix checkstyle errors in a java file

I have several checkstyle errors in a project I'm working on. I understand that there are two ways to fix checkstyle errors in eclipse with the checkstyle plugin which I mentioned in the title. Unfortunately, when I right-click on any error, "Quick Fix" is greyed out and right-clicking on a file then "Apply Checkstyle fixes" does nothing.
I've attempted to fix the issue from other stackexchange sources. This source claims that another quick-fix file needs to be made to actually fix the issues. However, this source (among others) mentions nothing of the sort.
I'm using Luna release 4.4.0. Is there something I'm missing or is quick fix only available for very certain checkstyle errors?
I'm running Luna 4.4.2 and thought I had the same issue, but it seems that "Quick Fix" isn't available for all reported problems. It took me a moment to realize, because I right clicked on the file previously and did a "Apply Checkstyle Fixes", so the only items remaining are the ones check style doesn't fix automatically.

Missing Quick-Fix solutions in Eclipse

So I'm using Eclipse for Java development but I'm getting annoyed that the "Quick-Fix" context menu is incomplete. In the Eclipse documentation, there's a full list of all the quick fixes for different common problems. If I press Ctrl+1 over an error, I get an incomplete list of "Quick-Fixes".
For Example, I know for a fact that "Create setters and getters" is a quick fix for instances where private variables in a class are never called.
However, this is not an option when I use the Quick Fix command for the item.
Also, quick fixes are NOT showing up in the context menu for items marked with errors. I have confirmed in Preferences > Java > Editor > Content Assist: that "Insert common prefixes automatically" is checked to True.
Is there possibly a problem with the JRE? (I DID have an issue earlier where the context menu wouldn't appear at all because eclipse couldn't find the .rt file. I had to decompress it and point eclipse to the folder containing the JRE before it would show anything.)
Any help would be greatly appreciated. Thanks in advance!!
So I feel so stupid but found the issue. Somehow, I installed the 2008, 3.3.2 version of Eclipse. Stumps me how it happened by it did. Lol. So After uninstalling and reinstalling the newest version of Eclipse, everything worked as expected. Thanks.

Eclipse shows incomplete links in tooltips

I've been living with a very annoying problem in Eclipse where if I declare a type that cannot be uniquely resolved, the tooltip that prompts me to choose the correct class sometimes does not display the full link.
As seen in the screenshot here, I have 9 different Version classes in my workspace, and only 3 of them display properly in the tooltip. The other 6 links still work, but I'd have to click on them first to see exactly which one gets imported.
I've had this problem for quite a while now, and updating to the latest Kepler release did not help. Has anyone else seen this problem or any idea how to debug this?
Specs:
Ubuntu x64 13.10
Eclipse 3.7.2 ~ 4.3.1
Anuparna provided the link in the comment which resolves my issue.
*Edit
Solution:
Go to General->Appearence->Colors and Fonts: Basic > Dialog Font and play around with the settings until you find something that works.

refresh out of date eclipse warnings

I have a warning in my Java code that I fixed. However, it remains in the "Problems" view. I can't figure out how to get eclipse to refresh it. It's even highlighting the wrong line (it's an unchecked cast, and it's displaying on the method header line)
I'm using eclipse 3.7.2 with the android development kit and the git plugin installed in the workspace, although this project is not an android project.
The project does not have a builder associated with it; I am building at the command line. I have cleaned and rebuilt everything and refreshed the project.
I've also tried removing org.eclipse.jdt.core and org.eclipse.core.resources/.projects//.indexes, and I've tried closing and re-opening the project.
Any suggestions?
Does the "Source" column of the problems view say "Android lint" for this warning, even though it is no Android project? If so, please upgrade the Android Development Tools plugin to the current version. In ADT 20.0.2 a bug was fixed which held outdated Java warnings/errors active even after fixing them.
See suggestion by original requester in comments for How to update warnings in Eclipse?
"Take a look in the 'Problems' view and delete the warnings manually."
Once the 'stuck' warnings are deleted normal Eclipse service should resume.

Categories