Setting build path has encountered a problem [message #520316] |
Thu, 11 March 2010 16:56  |
Eclipse User |
|
|
|
Project x and project y reside in the same eclipse workspace root directory. I am trying to add a jar file that resides in project x to project y by using Properties->JavaBuildPath->Libraries->Add Jars
After I do so and say ok, a window pops up with the following error message:
"Setting build path has encountered a problem
And Internal error occured during 'Setting build path'"
And the following stacktrace can be found in the log:
java.lang.NullPointerException
at org.eclipse.core.runtime.Path.<init>(Path.java:183)
at org.eclipse.core.internal.resources.WorkspaceRoot.getProject(WorkspaceRoot.java:179)
at org.eclipse.jdt.internal.core.ExternalFoldersManager.isExternalFolderPath(ExternalFoldersManager.java:77)
at org.eclipse.jdt.internal.core.JavaProject.addToResult(JavaProject.java:2651)
at org.eclipse.jdt.internal.core.JavaProject.resolveClasspath(JavaProject.java:2628)
at org.eclipse.jdt.internal.core.JavaProject.resolveClasspath(JavaProject.java:2679)
at org.eclipse.jdt.internal.core.JavaProject.getResolvedClasspath(JavaProject.java:1866)
at org.eclipse.jdt.internal.core.ProjectReferenceChange.updateProjectReferencesIfNecessary(ProjectReferenceChange.java:46)
at org.eclipse.jdt.internal.core.ChangeClasspathOperation.classpathChanged(ChangeClasspathOperation.java:59)
at org.eclipse.jdt.internal.core.SetClasspathOperation.executeOperation(SetClasspathOperation.java:62)
at org.eclipse.jdt.internal.core.JavaModelOperation.run(JavaModelOperation.java:728)
at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1800)
at org.eclipse.jdt.internal.core.JavaModelOperation.runOperation(JavaModelOperation.java:793)
at org.eclipse.jdt.internal.core.JavaProject.setRawClasspath(JavaProject.java:2890)
at org.eclipse.jdt.internal.core.JavaProject.setRawClasspath(JavaProject.java:2906)
at org.eclipse.jdt.internal.ui.wizards.buildpaths.BuildPathsBlock.flush(BuildPathsBlock.java:911)
at org.eclipse.jdt.internal.ui.wizards.buildpaths.BuildPathsBlock.configureJavaProject(BuildPathsBlock.java:735)
at org.eclipse.jdt.internal.ui.wizards.buildpaths.BuildPathsBlock.configureJavaProject(BuildPathsBlock.java:731)
at org.eclipse.jdt.internal.ui.preferences.BuildPathsPropertyPage$1.run(BuildPathsPropertyPage.java:214)
at org.eclipse.jdt.internal.core.BatchOperation.executeOperation(BatchOperation.java:39)
at org.eclipse.jdt.internal.core.JavaModelOperation.run(JavaModelOperation.java:728)
at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1800)
at org.eclipse.jdt.core.JavaCore.run(JavaCore.java:4694)
at org.eclipse.jdt.internal.ui.actions.WorkbenchRunnableAdapter.run(WorkbenchRunnableAdapter.java:106)
at org.eclipse.jdt.internal.ui.actions.WorkbenchRunnableAdapter$1.run(WorkbenchRunnableAdapter.java:121)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
After that, each time I go to Properties->JavaBuildPath->Libraries and click on any library the error window pops up again and another callstack show with a Nullpointer exception in org.eclipse.core.runtime.Path.<init>.
When I now try to close the workspace it says:
'Problems occured while trying to save the state of the workbench
Again a Nullpointer exception from the same location.
This does not happen always and with all jars in this directory. It seems to be rather random. I can't make any sense of it. I tried to delete the .classpath file of project y, even completely recreated project y, but nothing helped. If I have the jar that I want to use in project y's own project folder, I can add it without problems, but due to my build system's logic that is not an option for me.
Is this a known bug and is there a workaround?
[Updated on: Thu, 11 March 2010 17:01] by Moderator
|
|
|
|
|
|
|
Re: Setting build path has encountered a problem [message #527366 is a reply to message #520316] |
Thu, 15 April 2010 01:02  |
Eclipse User |
|
|
|
Same here. When closing Eclipse the following error is return "Problems occurred while trying to save the state of the workbench"
What works for me is I changed the security setting CHMOD on all files and sub-folders in my workspace folder. Especially the .settings folder located under
.../workspace/my-project-name-here/.settings/
IMPORTANT note: Often folders starting with a dot '.' are hidden by your OS. So you must first un-hide them. Then second change their permissions. Otherwise the permissions will be change only on visible folders & files.
[Updated on: Thu, 15 April 2010 01:14] by Moderator
|
|
|
Powered by
FUDForum. Page generated in 0.06381 seconds