This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
[ BUILD # : 49ed57cba68e ] [ JDK VERSION : 1.6.* ] After starting netbeans many java files in the Projects pane are annotated with the red exclamation mark. See screenshot attached. The description in the tooltip reads "Error parsing file". They are otherwise compiling files and projects. Opening the file in the editor shows no errors and soon the red annotation in the Project pane disappears. Opening the files seems the only way to remove the annotation badge. Such annotations also appear on package nodes, see second screenshot, despite there not being any files in the package with errors.
Created attachment 97416 [details] java files with "Error parsing file"
Created attachment 97417 [details] package with "Contains files with errors"
Created attachment 97418 [details] messages.log
> Opening the file in the editor shows no errors > and soon the red annotation in the Project pane disappears. In between the file opening in the editor and the red annotation in the Project pane disappearing is the "Scanning projects" task quickly running, when this task finishes the annotations promptly disappear.
Could you please go to var/cache/index subdirectory of your userdir, open file 'segments' and find segment number (s?) that belongs to the source root annotated with the error mark. After that go to s? subdirectory that corresponds to the segment number found. There should be folder 'errors' in it. Could you please attach its content to this issue? Thanks.
$ cd ~/.netbeans/dev/var/cache/index/s25/errors/1 $ find . -type f ./no/finntech/service/advert/impl/AdQueryImpl.java.warn ./no/finntech/service/advert/impl/LocationQueryImpl.java.warn $ cat ./no/finntech/service/advert/impl/AdQueryImpl.java.warn WARNING:-1:AdQueryImpl.java uses unchecked or unsafe operations. WARNING:-1:Recompile with -Xlint\dunchecked for details. $ cat ./no/finntech/service/advert/impl/LocationQueryImpl.java.warn WARNING:-1:LocationQueryImpl.java uses unchecked or unsafe operations. WARNING:-1:Recompile with -Xlint\dunchecked for details.
(In reply to comment #6) > $ cd ~/.netbeans/dev/var/cache/index/s25/errors/1 > > $ find . -type f > ./no/finntech/service/advert/impl/AdQueryImpl.java.warn > ./no/finntech/service/advert/impl/LocationQueryImpl.java.warn > > $ cat ./no/finntech/service/advert/impl/AdQueryImpl.java.warn > WARNING:-1:AdQueryImpl.java uses unchecked or unsafe operations. > WARNING:-1:Recompile with -Xlint\dunchecked for details. > > $ cat ./no/finntech/service/advert/impl/LocationQueryImpl.java.warn > WARNING:-1:LocationQueryImpl.java uses unchecked or unsafe operations. > WARNING:-1:Recompile with -Xlint\dunchecked for details. Is this at the time the errors are shown in the projects tab? Could you please list all error and warning files in all var/cache/index (something like: find */errors/1 -type f) and cat any files that end with .err? Thanks.
For now (cause i opened all the erred files) i can only reproduce the package that's annotated as red with no red annotated files in it. Here the only listing is ./s692/errors/1/no/finntech/control/controller/realestate/HomesController.java.err a file that no longer exists in the project.
I got it again with a brand new project group. This time with file named BapDebugAction.java $cat s732/errors/1/no/finntech/actions/shop/BapDebugAction.java.err ERROR:122:cannot find symbol\n symbol\d method sendExpiredFlexi(no.finntech.base.modules.organisation.support.OrganisationBean)\n location\d interface no.finntech.base.modules.shop.ShopEmailService ERROR:134:cannot find symbol\n symbol\d method sendFlexiAboutToExpire(no.finntech.base.modules.organisation.support.OrganisationBean)\n location\d interface no.finntech.base.modules.shop.ShopEmailService Opening the file in the editor showed no such error and soon (after a quick "scanning projects" task ran) the badge in the explorer disappeared. And still with the "no.finntech.control.controller.realestate" package. Here there exists a var/cache/index/s692/errors/1/no/finntech/control/controller/realestate/HomesController.java.err but this java file has over a week been removed from the project. Highlight from messages.log: WARNING [org.netbeans.modules.java.source.tasklist.IncorrectErrorBadges]: Incorrect error badges detected, file=/usr/local/src/finn-src/iad-trunk-clean/actions/src/main/java/no/finntech/actions/shop/BapDebugAction.java. WARNING [org.netbeans.modules.java.source.tasklist.IncorrectErrorBadges]: Going to recompute root=/usr/local/src/finn-src/iad-trunk-clean/actions/src/main/java, files in error=[file:/usr/local/src/finn-src/iad-trunk-clean/actions/src/main/java/no/finntech/actions/shop/BapDebugAction.java]. but nothing interesting from the "-Dorg.netbeans.modules.parsing.impl.indexing.RepositoryUpdater.level=FINE" logger. I've attached this same messages.log
Created attachment 97845 [details] messages.log related to comment #9
(In reply to comment #10) > Created an attachment (id=97845) [details] > related to comment #9 ( http://netbeans.org/bugzilla/show_bug.cgi?id=184233#c9 > ) I experienced the same problem. I resolved it by temporarily recreating the missing file (based on the corresponding .err file found by a global search for .err files in my var/cache/index subdirectory of myuserdir complaining for a file missing within the problematic package) and deleting it again. The error annotation disappeared then.
I also have a similar problem, but the red file annotation does not disappear when I open or re-save the file. NetBeans 6.9.1 Java SE 6 Maven 2.2.1 Mercurial
I set the priority to P2 as this is a major distraction/ misinformation if my source code is OK or not.
I have found a problem related to excludes on sourcepath (bug #194174) and there are some known problems related to maven projects (bug #188323). Unfortunately without specific steps to reproduce it is impossible to say if the problem described here are related to any of these bugs and without such steps to reproduce it is virtually impossible to fix them. If anybody could provide specific steps how to reproduce, it would be most welcome. I was testing what seemed suspicious to me, but only outcome was #194174, in which case the error badges are corrected on next IDE restart, and so it does not seem to be related to problems described here. Thanks.
I had similar error: in the project pane only the project itself had a red error flag saying "Contains files with errors", but in the files pane almost all source files had an error flag. If you opened the source files from here inside it said that the import packages are not found (even so the classpath to the libraries is set correctly). In my case the problem was, that there were two possible path to the project: one through the real path to the project folder and a second one through a symlink (which I created to access the folder faster). While the project was set up on the real path, the path to the source folders was defined via the symlinked path. After deleting the symlink and reassigning the path to the source folder the error disappeared.
I just encountered the same problem with version 7.3.1. Everything is fine until Netbeans runs a "scanning files" operation, which is then interrupted by "low memory" error. After that, Netbeans begin to have trouble parsing one of the files.
The conditions you've described (OOM followed by parsing problems) seems to be different from those reported earlier. Please open a separate defect. There are also other issues regarding to incorrect 'error' badge (e.g. issues #214630, #170190, #219204, #233933), but those do not report preceding OOM, which may twist things. Reverting the target milestone and status; please file a separate report for the unique scenario. Thanks.