Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 560289

Summary: The resource is not on the build path of a java project error
Product: [Eclipse Project] JDT Reporter: James Peng <oldyoungguy88>
Component: UIAssignee: JDT-UI-Inbox <jdt-ui-inbox>
Status: CLOSED INVALID QA Contact:
Severity: blocker    
Priority: P3 CC: Lars.Vogel
Version: 4.14   
Target Milestone: ---   
Hardware: PC   
OS: Windows 7   
Whiteboard:

Description James Peng CLA 2020-02-18 13:43:50 EST
I have been using Eclipse for more than 10 years. I just started to use Eclipse IDE for Enterprise Java Developer 2019-12 edition. In the past week, I was blocked by "The resource is not on the build path of a java project" error three times right in the middle of the development. The feeling is really bad. Just cannot figure out what was happened. Fortunately, I was able to make it works for me again twice by closing and delete the project and re-import the project again. But this doesn't always work. Another time I have to close the Eclipse and delete the .classpath file because I found it was modified but I don't know if that is the reason for the error. 

The last time happened 10 minutes ago. I just did a File Search and click one of the results to find where it is in the code. Then I tried to see who is the callers of the method. The error happened. Nothing special, just a normal day for Eclipse but it refused to work for me then. Before that moment, the functionality works perfectly. After close/delete/import the same project, it works again. Also tried other things, like import the epf file again, close and launch Eclipse again. None fixes the issue.
Comment 1 Lars Vogel CLA 2020-02-18 13:55:53 EST
Moving to JDT for investigation. 

Something special with the project? Any way to provide a reproducable example?
Comment 2 James Peng CLA 2020-02-18 13:58:40 EST
I just found it probably is an user error. I will report it again if it happens.
Comment 3 Lars Vogel CLA 2020-02-18 14:15:31 EST
Great to hear James, thanks for the feedback.