I am facing a problem, as the title suggests, have no idea what happened here. My eclipse does not show comments/docs in bubble any more. As you can see I have written some comments on a method but still it would not show them.
Note: I have restarted eclipse + PC several times without any success. The comments do not even appear for my own methods.
Please help
IDE's can be very moody sometimes. Try either completely restarting eclipse or restarting your machine all together. If all else fails, reinstall.
Eclipse may not showing code docs in different situations -
The code may have not java doc
Or the jar file for the code is not added in eclipse classpath
Related
I was working on eclipse two days ago, and closed it properly.
Now, when I'm trying to start it, I get the splash screen popping for a blink of an eye, then disappearing.
I get:
no error message, and
no error is logged in the <workspace>\.metadata\.log file (the last errors logged there are from two days ago).
Apparently, the problem isn't with the workspace, because I changed the SHOW_WORKSPACE_SELECTION_DIALOG argument in <eclipse>\configurations\.settings\org.eclipse.ui.ide.prefs to true, and it doesn't even get as far as showing the dialog.
There's only one thing I can recall I did before it stopped working - I have installed a plugin for UFT Java Extensibility SDK from HP.
Needless to say uninstalling it didn't help.
Is there any other log I can hope to find helpful?
Or anything else I can do to get it to work?
EDIT:
I was just trying to start another instance of eclipse I have (adt-bundle-windows-x86-20130219), and got the same outcome.
EDIT:
I added Java & QTP to the title in order to help others who bumps into the same issue.
If the JRE is somehow the issue, try installing a JDK (not a JRE), in a non-default path (for instance, C:\Prog\Java\JDK1.7.0_xx), and make sure your eclipse.ini explicitly reference that JDK.
-vm
C:/Prog/Java/jdk1.7.0_21/jre/bin/server/jvm.dll
(you can use '/' even on Windows in an eclipse.ini file)
The problem was indeed with Java (Thanks Arne). Re-installing the jre didn't help, so I also tried to deleted the JAVA_OPTIONS and JAVA_TOOL_OPTIONS enviroment variables, which solved the problem.
Later, I found this discussion which seems related to my problem: http://h30499.www3.hp.com/t5/Unified-Functional-Testing/Environment-variables-JAVA-OPTIONS-and-JAVA-TOOL-OPTIONS-is/td-p/5855995.
I will look more deeply into it later, when I will start using HP's plugin, but I hope this thread can help others who run into trouble with eclipse after installing this plugin.
I've installed Eclipse and tried to do the "Hello World" program a couple of times and for some reason it never seems to work, could anyone help me out with this because I'm quite lost seeing as I've never used Eclipse before, heres a screenshot of my UI and what I get as an error:
Also I may have forgotten something very basic knowing me, seeing as it's been months since I last programmed, feel free to mention it nonetheless.
You are trying to run a program full of compiler errors, so no wonder it doesn't work. In your case it's the JRE configuration—you need to bind your installed JRE to the Eclipse's JRE setup. You can type Ctrl-3, jre, enter and you'll be able to go directly to the proper preference page.
Eclipse is not able to find HelloWorld.class file. Might be due to compile time problems.
You can check in the output directory of your project, weather .class file is there or not.
I am having a problem with Eclipse where I can run my program just fine, but when I try to start the debugger, I get this message
The picture is a little hard to make out, but instead of getting the normal debugging window, instead it says it is throwing a ClassNotFoundException, and is trying to dislay the source for Launcher$ExtClassLoader.
The thing that really baffles me though is that I can run the code just fine, it is only when I click the debug button that I have the problem.
I have also tried debugging at the command line with JDB, and I got the same error.
So far, I have tried Reinstalling Eclipse and downloading (what I believe to be) the correct Java Development tools for Mac OS X.
I have no idea what else I can try, so any help would be greatly appreciated. Let me know if there is any other information I can provide.
Source not found might be legitimate for dynamically loaded code (e.g. Maven).
There are three workarounds known to me (after months of search):
Connect to a running JVM with the debugger and you will see the code.
Use Dynamic Source Lookup plugin for Eclipse from here:
https://github.com/ifedorenko/com.ifedorenko.m2e.sourcelookup
Use run-jetty-run Maven plugin
http://code.google.com/p/run-jetty-run/
I prefer and recommend 3. It works and starts webapp much faster than jetty:run.
Unfortunately 2. didn't helped me as it has issues with Windows paths with spaces.
I have filled an enhancement request on Eclipse Bugzilla and if you agree this issue "Source not found" should vanish forever, please vote for it here:
https://bugs.eclipse.org/bugs/show_bug.cgi?id=384065
Do you have the sources for the files that you are using. If you are using Maven (M2Eclipse) you could download the sources. This might solve the problem.
Otherwise you could go and manually attach your sources. Here is how you manually attach sources.
Next you have to attach the sources-
Hope this helps
The "source not found" is a red herring - there may simply be no way to get access to the source that is throwing the error, because it is deep in the guts of the debugger's class loader.
The better question, then, is, "Why is scottrice.ChessPuzzles.ChessPuzzleDriver not being found?" The only possibility that occurs to me at the moment is that something might be weird in your debug configuration. Did you debug the program by just right-clicking a file with a main() and choosing "Debug As" -> "Java Application"?
I'm trying to help another developer who is using Netbeans. When he runs or debugs some code of his in Netbeans (6.9.1) he gets an "Uncompilable source code" RuntimeException. I'm pretty experienced in Java but am more used to IntelliJ, and haven't used Netbeans at all.
I've done it a bit of googling and it seems Netbeans will compile code even with errors, and then throw the RuntimeException at the errors. (Fairly bad behaviour IMO, but I guess some will find it useful.) I've got him to completely rebuild the project with no compile errors, but the RuntimeException seems to still occur. I assume he's got some bad cached class data somewhere deep within Netbeans.
2 questions:
What is the best way to clear the cache so we can find out where the uncompilable code is?
Is there any way of turning off this behaviour so the code won't run/debug unless everything will compile, so these RuntimeException's won't be injected into the code?
I've googled a fair bit, but haven't found the answer to either of these questions yet.
Update: More information:
Turning off the "compile on save" option makes the problem go away. Turning CoS back on again brings the exception back. Unfortunately this isn't a fix, as CoS is a very useful option.
http://netbeans.org/bugzilla/show_bug.cgi?id=182009 seems the closest bug report, but it has been closed as "RESOLVED INCOMPLETE". Unfortunately the bug is hard to reproduce - the exception is happening in Java library code, when it calls a third-party library, so there isn't anything at the point the exception is thrown we can change. And the code will work for weeks, and then suddenly start throwing this error with no obvious reason why.
We've tried manually deleting the entire build directory - still not a fix.
We finally got a solution, but still don't quite know why the situation occurs. When you have Compile On Save activated, Netbeans generates a second set of class files for debugging etc. These are stored in $USER/.netbeans/var/cache/index/s*/java/*/classes
Somehow (not sure how) this directory can get corrupted or fail to update.
If you close netbeans, delete $USER/.netbeans/var/cache/index and all subdirectories and restart netbeans this clears the cache. If you have no compile errors, your problem ought to go away at this point.
NB: $USER is your user directory - on Windows 7 this is usually c:\Users\username, I guess on Unix it will be ~username.
If you get this problem please vote for, comment on, or add information to: http://netbeans.org/bugzilla/show_bug.cgi?id=182009
I experienced the same wired problem in NB 7.0.1, my hammer-IQ solution was to make a typo in the source code, run NB with this error (despite an error message) and than the cached class was successfully deleted.
I experienced this issue on Linux Mint Nadia with Netbeans 7.2.1, but was stumped as to where the cache location might be - mine was actually located at
/home/USER/.cache/netbeans/7.2.1
rather than in the .netbeans folder.
If you're not sure where the cache is located on your particular setup, just go to the help > about menu in Netbeans and it'll tell you the correct path.
After realising that the cause was a bad cache from the other posted solutions, I solved this problem by copying the file to another directory, deleting it from NetBeans, and then adding it again.
In fact, you neednt delete whole of index folder.
When you open netbeans and your project folder is active. Netbeans starts scanning files and creates temporary project folders (in index folder) for all active projects. If you check index\segments file(its a text file and can be viewed in notepad/(text editor)), you will be able to identify the folders that represent your project. You can then delete those folders and restart netbeans.
*Active project means those projects that were open before Netbeans was shutdown.
Had the same problem on Windows 7 with Netbeans 12.
Cache is here:
C:\Users\<Username>\AppData\Local\NetBeans\Cache
, but the deleting cache is not helpful sometimes. The better solution is to recompile the problematic class i.e. make a minor change (e.g. add space) and save.
I have a problem that seems to come up both with autocomplete and quick fix. Sometimes when I use cmd+1 for quick fix dialog, Eclipse freezes and however long I wait (30 min at least), nothing happens. When inspected in activity monitor, it seems to exhibit little to no processor activity.
I have a Mac with OSX 10.6, and Helios with no weird plugins. I program in java, so I use very standard features.
Is this a known bug? I have tried to google a lot to find useful info. I am not very good at reading bug reports though, and the concept of feature freeze kind of taints my search results.
Thanks for any help.
As for Eclipse you can not know what is happening. The whole platform is a set of plugins, and the requirements (for example responsiveness) are not strict for them. So a third party or even a bundled plugin can cause such a failure. So most of times you cannot have a clue about what is wrong. Some stuff you can do:
while hanging unplug your network connection. If you are behind a proxy for example, a plugin can wait for a long time on network io
you can check with for example resource monitor, which file eclipse opened. Some of the opened file handlers can have relation with the problem
edit .classpath file in project where code completion freezes, and it will "reset" your project stuff in eclipse
you can browse .metadata folder in eclipse workspace and you can guess which folder to remove temporaly. After removing, try if error is still present
create a new workspace and import projects into it
if new workspace do not work, then the eror is in configuration folder in eclipse root, and you can play the same thing like in step 4
use a brand new eclipse
+1. Maybe some new plugin is responsible. In eclipse Help/about/installation details/Installation history tab you can revert to some older set of plugins.
Hope it will help.
Seems that you encounter known and already fixed bug.
Issue fixed after deleting all the files in the below directory
configuration\org.eclipse.osgi\.manager
.fileTableLock
.fileTable.1
.fileTable.2
There will be fileTable lock files, delete all those files