Community
Participate
Working Groups
Fup of bug 321358, it looks like there is a bunch of new problems with external folders with 3.6.1 that didn't exist with either 3.6.0 or 3.5.2. See bug 321358 comment 18.
*** Bug 326517 has been marked as a duplicate of this bug. ***
This bug and 321358 both were exposed by the fix for bug 313153, which removed a null-check in question. The null-check was put back in HEAD but not for 3.6.x. Now that we seem to be having reproducible scenarios in 3.6.1, I will investigate and see what the cause is.
Though many people have reported this, what we clearly didn't have here was a reproducible test case. Now that some of you can consistently reproduce the bug, can any of you share the affected workspace? This will help us fix the cause rather than just adding a null-check.
This happens now EVERY TIME when I start Eclipse (after upgrade to Helios)! My Workspace is way over 300 MB ... !ENTRY org.eclipse.core.jobs 4 2 2010-09-30 12:12:05.703 !MESSAGE An internal error occurred during: "Refreshing external folders". !STACK 0 java.lang.NullPointerException at org.eclipse.jdt.internal.core.ExternalFoldersManager$RefreshJob.run(ExternalFoldersManager.java:387) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
(In reply to comment #4) > This happens now EVERY TIME when I start Eclipse (after upgrade to Helios)! My > Workspace is way over 300 MB ... > > > !ENTRY org.eclipse.core.jobs 4 2 2010-09-30 12:12:05.703 > !MESSAGE An internal error occurred during: "Refreshing external folders". > !STACK 0 > java.lang.NullPointerException > at > org.eclipse.jdt.internal.core.ExternalFoldersManager$RefreshJob.run(ExternalFoldersManager.java:387) > at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54) I understand it is not possible to attach the entire workspace here. Would it be possible to provide access to the environment?
Just a tip, maybe it helps to define right search direction: the NPE is gone when I closed all my projects and opened them again.
(In reply to comment #6) > Just a tip, maybe it helps to define right search direction: the NPE is gone > when I closed all my projects and opened them again. Thanks. That's expected given that the external folders project file would have been recreated/updated when you did that. Right now the only way I can reproduce the NPE is by manually removing the link folders from the external folders projects. But I don't know what is causing it.
I think for now, what we can do is to apply the fix for bug 321358 in 3.6 as well. I will post the patch and release unless someone can provide me a reproducible test scenario.
Created attachment 180124 [details] Patch Patch has the null check.
Released in R3_6_maintenance for 3.6.2
+1 for 3.6.2.
How can I get this fix? I'm getting these NPE crashes all the time (my environment is set up to refresh continually). Is there any way I can patch my eclipse 3.6.1 installation, or can I download a J2EE package of an interim build anywhere?
(In reply to comment #12) > How can I get this fix? I'm getting these NPE crashes all the time (my > environment is set up to refresh continually). Is there any way I can patch my > eclipse 3.6.1 installation, or can I download a J2EE package of an interim > build anywhere? There is a workaround, just read the comment #6
(In reply to comment #13) > > There is a workaround, just read the comment #6 Done it, also deleted and re-imported all projects, restarted Eclipse, still happening.
(In reply to comment #13) > There is a workaround, just read the comment #6 I can close/reopen my projects as much as I want it does not make the "Refreshing external folders" errors go away. PS: Saving any file in an Android project causes the error as well.
(In reply to comment #12) > How can I get this fix? I'm getting these NPE crashes all the time (my > environment is set up to refresh continually). Is there any way I can patch my > eclipse 3.6.1 installation, or can I download a J2EE package of an interim > build anywhere? This is one way to fix your issue. 1) update to the build M20101006-0936 2) Checkout org.eclipse.jdt.core from eclipse cvs: :pserver:anonymous@dev.eclipse.org:/cvsroot/eclipse and you choose the branch R3_6_maintenance. Then once it is compiled, you export it as a bundle into the running host. Once this is done, you restart and the new version of jdt.core that contains the fix will be installed. Let me know if you have any issue.
(In reply to comment #16) > Once this is done, you restart and the new version of jdt.core that contains > the fix will be installed. > Let me know if you have any issue. That works just fine. No more errors during startup or after saving a file in an Android project. Thanks!
(In reply to comment #16) Thanks for the help. I'm afraid it's a bit beyond me, though... :-) I'll turn off auto refresh and wait for the next package release.
(In reply to comment #18) > Thanks for the help. I'm afraid it's a bit beyond me, though... :-) > I'll turn off auto refresh and wait for the next package release. You can contact me offline for further help. I'll guide you through the steps.
I was also receiving this error until I installed SpringSource Update Site for Eclipse 3.6 - http://dist.springsource.com/milestone/TOOLS/update/e3.6 and it has since been resolved. Hopefully this helps!
This may or main not help finding the original cause of the issue, but I started having those problems after I have migrated to a new machine and accidentally called one directory "Java" instead of "java" (on windows). So in my .classpath I had: <classpathentry exported="true" kind="lib" path="commons-collections.jar" sourcepath="D:/java/.src/commons-collections-3.1/src/java"/> where is getAbsolutePath() would return this: D:/Java/.src/commons-collections-3.1/src/java (note capital "J") I wonder if the root cause of this NPE is some case sensitive lookup or equal on pathname which happens just before. Hope this would help.
Getting the NPE on external folder refresh every time I do a build (which is probably when the refresh occurs.) Just got a new variation of this in "Activity Monitor Job". eclipse.buildId=M20100909-0800 java.version=1.6.0_21 java.vendor=Sun Microsystems Inc. BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_US Framework arguments: -product org.eclipse.epp.package.jee.product Command-line arguments: -os win32 -ws win32 -arch x86 -product org.eclipse.epp.package.jee.product -data c:/EclipseWorkspace3.6/Trunk Error Thu Oct 14 14:10:03 GMT-07:00 2010 An internal error occurred during: "Activity Monitor Job". java.lang.NullPointerException at org.eclipse.mylyn.internal.tasks.ui.TaskListSynchronizationScheduler.cancel(TaskListSynchronizationScheduler.java:107) at org.eclipse.mylyn.internal.tasks.ui.TaskListSynchronizationScheduler.userAttentionGained(TaskListSynchronizationScheduler.java:155) at org.eclipse.mylyn.internal.monitor.ui.ActivityContextManager.fireActive(ActivityContextManager.java:219) at org.eclipse.mylyn.internal.monitor.ui.ActivityContextManager.access$2(ActivityContextManager.java:217) at org.eclipse.mylyn.internal.monitor.ui.ActivityContextManager$2.active(ActivityContextManager.java:93) at org.eclipse.mylyn.internal.monitor.ui.CheckActivityJob.run(CheckActivityJob.java:101) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
(In reply to comment #6) > Just a tip, maybe it helps to define right search direction: the NPE is gone > when I closed all my projects and opened them again. Just closed all projects and reopened only the one I need plus the three it references. Got the NPE on refresh as soon as the open performed.
I have been getting the NPE consistently. After reading all these comments, I started checking my project classpath files looking for upper/lower case issues. I found two entries that configure a sourcepath for jars: <classpathentry kind="lib" path="lib/choiceutil.jar" sourcepath="/dbaccess/src"/> <classpathentry kind="lib" path="lib/dbaccess.jar" sourcepath="/dbaccess/src"/> The referenced project was closed. After I opened the project, the NPE did not occur when I did the build. So at least in my case, the issue seems related to a sourcepath to a closed project. HTH Michael
(In reply to comment #24) > I have been getting the NPE consistently. After reading all these comments, I > started checking my project classpath files looking for upper/lower case > issues. > > I found two entries that configure a sourcepath for jars: > > <classpathentry kind="lib" path="lib/choiceutil.jar" > sourcepath="/dbaccess/src"/> > <classpathentry kind="lib" path="lib/dbaccess.jar" sourcepath="/dbaccess/src"/> > > The referenced project was closed. After I opened the project, the NPE did not > occur when I did the build. So at least in my case, the issue seems related to > a sourcepath to a closed project. > > HTH > Michael Possibly a false alarm. After doing a couple of builds, the issue returned. I've had to back out of 3.6.1 back to 3.6.0. Will watch for 3.6.2.
*** Bug 328615 has been marked as a duplicate of this bug. ***
> Just a tip, maybe it helps to define right search direction: the NPE is gone > when I closed all my projects and opened them again. Yahoo! This also worked for me (Helios, Build 20100917-0705). :-)
NPE was triggered in my environment due to the following line in .classpath: <classpathentry kind="lib" path="web/app/WEB-INF/lib/semanticvectors-1.27.jar" sourcepath="/semanticvectors"/> The file web/app/WEB-INF/lib/semanticvectors-1.27.jar does exist under the project root, but the source folder /semanticvectors does not, neither does it exist under workspace root. Relevant logic is in ExternalFoldersManager.getExternalFolders(IClasspathEntry[] classpath) lines 75-79. The sourcepath folder does not exist in workspace, hence it's determined to be external. Perhaps treatment of missing source attachments should be more lenient than that of missing libraries. The latter the user should be notified about (at least via warning), the former can be silently ignored. In any case, an NPE is hardly the most graceful way to report an error, as the path of the non-existent external folder doesn't go into the log. P.S.: One of the most popular Eclipse plugins, FindBugs, would've neatly picked up this issue.
I figured it out. I had a classpath variable being referenced by a library source entry in my project's build path, and that classpath variable was undefined.
The error in my case started after doing some changes in folders of link type. Included deleting and/or editing I am not sure. My workspace consists of a mixture of java, java web and android projects, all connected with dependencies. However my android projects were closed all the time. The error was triggered the first time after load I was clicking on the parent folder that used to contain the linked folders. It kept persisting after I moved all the linkedResource entries from the .project file. The frequency has rendered eclipse unusable (every few seconds) I applied the workaround from comment #6 (closed and re-opened everything) and I am very happy that the problem went away. Thanks!
(In reply to comment #30) Version: Helios Service Release 1 Build id: 20100917-0705
This is not fixed! I just downloaded the Heölios Service Release 1 (Eclipse IDE for Java Developers), Build ID 20100917-0705 and everytime I start Eclipse, I get this: ----------------------------------------- !ENTRY org.eclipse.core.jobs 4 2 2010-11-23 15:33:37.871 !MESSAGE An internal error occurred during: "Refreshing external folders". !STACK 0 java.lang.NullPointerException at org.eclipse.jdt.internal.core.ExternalFoldersManager$RefreshJob.run(ExternalFoldersManager.java:387) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54) --------------------------------------------
(In reply to comment #32) > This is not fixed! I just downloaded the Heölios Service Release 1 (Eclipse IDE > for Java Developers), Build ID 20100917-0705 and everytime I start Eclipse, I > get this: The target is 3.6.2 and not 3.6.1. Grab the latest M-build and give it a try.
(In reply to comment #33) > The target is 3.6.2 and not 3.6.1. > Grab the latest M-build and give it a try. What is an "M-build"? When I close all projects, Eclipse stays calm. But now, when I open some projects (to work with Eclipse...) the NullPointerException just pops up every once in a while!
(In reply to comment #34) > What is an "M-build"? You will find all the developer builds here: http://download.eclipse.org/eclipse/downloads/ The "3.6.x Stream Builds" section has the recent M builds.
Why do I need to download a "Developer Build"? This is a major issue as this NullPointerEyxception pops up several dozen times a day and I expect to click Help > Check for Updates to fix this issue. What is "Check for Updates" good for, if it doesn't update to a bug fix version? Anyway: the site (http://download.eclipse.org/eclipse/downloads/drops/M20101124-0800/index.php) shows that the windows 32 bit version (that I need) has a red cross => not usable???
(In reply to comment #36) > Help > Check for Updates If you point to this update site http://download.eclipse.org/eclipse/updates/3.6.x, you will be able to update to each M-build. > to fix this issue. What is "Check for Updates" good for, if it doesn't update > to a bug fix version? This is because you didn't set up the right update site. > Anyway: the site > (http://download.eclipse.org/eclipse/downloads/drops/M20101124-0800/index.php) > shows that the windows 32 bit version (that I need) has a red cross => not > usable??? Perfectly fine from our point of view.
Downloaded eclipse-SDK-M20101124-0800-win32.zip - the NPE is now gone. :-) >This is because you didn't set up the right update site. Well, if I download an official release, I expect "check for updates" to have the necessary bug fix update site already configured.
(In reply to comment #38) > Well, if I download an official release, I expect "check for updates" to have > the necessary bug fix update site already configured. 3.6.2 is not available yet. So the official update site for Helios doesn't contain the M-build contents as long as 3.6.2 is not declared. If you want to update to M-build between 3.6.1 and 3.6.2, then you need to use the update site I mentioned in comment 37.
Ah, now I understand. So the normal "check for updates" would have fixed this issue - anytime when it is "released". But as I have this bug for weeks, I could have used this fix as soon as possible. There should be some hotfix patches that repair such annoying bugs. NullPointerExceptions are eval and at least they can easily be traced and fixed.
(In reply to comment #40) > Ah, now I understand. So the normal "check for updates" would have fixed this > issue - anytime when it is "released". But as I have this bug for weeks, I > could have used this fix as soon as possible. There should be some hotfix > patches that repair such annoying bugs. NullPointerExceptions are eval and at > least they can easily be traced and fixed. Eclipse releases two maintenance fixes for each major releases through "official" release train update sites. You can get hotfix patches using the maintenance update site every week. This is true only for the platform. The release train update site contains latest update of all projects on the Eclipse release train. At least now you know where to go to get the latest fixes in the platform every week.
the update site in comment#37 cannot be used due to dependency problems: our original request has been modified. "Eclipse Platform" is already installed, so an update will be performed instead. "Eclipse RCP" is already installed, so an update will be performed instead. Cannot complete the install because of a conflicting dependency. Software being installed: Eclipse SDK 3.6.2.M20101124-0800 (org.eclipse.sdk.ide 3.6.2.M20101124-0800) Software currently installed: Eclipse IDE for Java EE Developers 1.3.1.20100916-1202 (epp.package.jee 1.3.1.20100916-1202) Only one of the following can be installed at once: Eclipse Platform 3.6.0.v201006080911 (org.eclipse.platform 3.6.0.v201006080911) Eclipse Platform 3.6.1.v201009090800 (org.eclipse.platform 3.6.1.v201009090800) Eclipse Platform 3.6.1.v201011240800 (org.eclipse.platform 3.6.1.v201011240800) Cannot satisfy dependency: From: Eclipse IDE for Java EE Developers 1.3.1.20100916-1202 (epp.package.jee 1.3.1.20100916-1202) To: org.eclipse.epp.package.jee.feature.feature.group [1.3.1.20100916-1202] Cannot satisfy dependency: From: Java EE IDE Feature 1.3.1.20100916-1202 (org.eclipse.epp.package.jee.feature.feature.group 1.3.1.20100916-1202) To: org.eclipse.platform.feature.group [3.6.1.r361_v20100909-9gF78GrkFqw7GrsZnvz0JWNTeb6fue6896L] Cannot satisfy dependency: From: Eclipse Platform 3.6.1.r361_v20100909-9gF78GrkFqw7GrsZnvz0JWNTeb6fue6896L (org.eclipse.platform.feature.group 3.6.1.r361_v20100909-9gF78GrkFqw7GrsZnvz0JWNTeb6fue6896L) To: org.eclipse.platform [3.6.1.v201009090800] Cannot satisfy dependency: From: Eclipse Platform 3.6.2.r362_v20100929-9gF78GrwFrIFgk8HTs_QpPx3VCeZS8h1E7-wVg (org.eclipse.platform.feature.group 3.6.2.r362_v20100929-9gF78GrwFrIFgk8HTs_QpPx3VCeZS8h1E7-wVg) To: org.eclipse.platform [3.6.1.v201011240800] Cannot satisfy dependency: From: Eclipse Project SDK 3.6.2.r362_v20100929-7Q7m7ED5cWkEfx66Dl07n6ekFYja7RW3ujEvoWERrKYw6 (org.eclipse.sdk.feature.group 3.6.2.r362_v20100929-7Q7m7ED5cWkEfx66Dl07n6ekFYja7RW3ujEvoWERrKYw6) To: org.eclipse.platform.feature.group [3.6.2.r362_v20100929-9gF78GrwFrIFgk8HTs_QpPx3VCeZS8h1E7-wVg] Cannot satisfy dependency: From: Eclipse SDK 3.6.2.M20101124-0800 (org.eclipse.sdk.ide 3.6.2.M20101124-0800) To: org.eclipse.sdk.feature.group [3.6.2.r362_v20100929-7Q7m7ED5cWkEfx66Dl07n6ekFYja7RW3ujEvoWERrKYw6]
You are right. According to what you installed, you might end up with dependency issues. So basically, you would need a complete release train update. This is beyond the scope of this bug. Nothing prevents you from installing locally the latest version of jdt.core from the R3_6_maintenance stream.
I'm running Eclipse Helios and had the same problem when refreshing one of my projects. In the Properties > Java Build Path > Libraries page, I went through and verified the source and javadoc specifications for the jars in my classpath by re-selecting the external file/folder path. That seems to solve the problem b/c now after a refresh, I no longer get the NullPointerException.
w.r.t comment#43, i downloaded org.eclipse.jdt-M20101215-0800.zip from the 3.6.x Stream Build link on http://download.eclipse.org/eclipse/downloads/. I assume that is what is being referred to by R3_6_maintenance but I'm not sure. At any rate, I unzipped the above in eclipse dir, and started with 'eclipse -clean' and still get the exception. is there some other stream build that is being referred to? otherwise, should I re-open the bug?
(In reply to comment #45) > At any rate, I unzipped the above in eclipse dir, and started with 'eclipse > -clean' and still get the exception. is there some other stream build that is > being referred to? > > otherwise, should I re-open the bug? Please check whether the new JDT/Core plugin has been picked up by the IDE? With the download you specified, the org.eclipse.jdt.core plugin's version should be 3.6.1.v_A71_R36x. Go to "Help -> About Eclipse -> Installation details -> Plug-ins" to look up.
you're right, it isn't picking it up. i have both the old and the new jars in the directory. it's picking up the old one (jar org.eclipse.jdt.core_3.6.1.v_A68_R36x.jar). however, if I remove the old jar, i get no JDT functionality, even though the org.eclipse.jdt.core_3.6.1.v_A71_R36x.jar jar is in the directory right there. after putting the old jar back (both are there again), i tried editing artifacts.xml to put the new version but it didn't make any difference - still getting the old jar. is there a way to "install" the downloaded zip other than unzipping in eclipse dir?
I would also like to know, how to integrate a maintenance build into an existing eclipse installation.
(In reply to comment #48) > I would also like to know, how to integrate a maintenance build into an > existing eclipse installation. The right place to discuss this would be the eclipse forum.
(In reply to comment #49) > (In reply to comment #48) > > I would also like to know, how to integrate a maintenance build into an > > existing eclipse installation. > > The right place to discuss this would be the eclipse forum. Yeah, probably, sorry!
(In reply to comment #6 and comment #27) > > Just a tip, maybe it helps to define right search direction: the NPE is gone > > when I closed all my projects and opened them again. > > Yahoo! This also worked for me (Helios, Build 20100917-0705). :-) thanks, worked 4 me too (Helios, Build 20100917-0705) updated to this build at monday, used the new directory for new installation. other directory 4 workspace, same directories 4 projects
Verified for 3.6.2 RC2 using build M20110119-0834
*** Bug 340419 has been marked as a duplicate of this bug. ***