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.
Product Version: NetBeans IDE Dev (Build 200911171401) Java: 1.5.0_20; Java HotSpot(TM) Client VM 1.5.0_20-141 System: Mac OS X version 10.5.8 running on i386; MacRoman; en_US (nb) 1. Create a new Java application (for example...) 2. Right-click Source Packages node 3. Invoke New>Java Class 4. Fill in NewClass in the class name and "a.b.c" in the package name 5. Confirm the dialog -> projects view displays: Source Packages +- a +- a.b +- a.b.c +- NewClass.java -> expected: Source Packages +- a.b.c +- NewClass.java
Caused by Milan's changeset 03e06da26d49. Rollback the change for 6.8 should be the best solution. Reassigning to Milan.
Fixed. (Rollbacked fix of issue #175997). http://hg.netbeans.org/core-main/rev/8497a06e01fd
I've spent some time to debug this problem. The problem among lots of others problems in package view (races and 2-3 threads per handling single fs change) is when several event comes from AWT-Event thread. In this case the nodes are not created as the refreshKeysAsync defers nodes creation to the end of AWT event queue. But the cleanEmptyKeys requires the nodes, the intermediate nodes are not removed. I've rewritten the cleanEmptyKeys to work even when the nodes are not yet created. I will attach a patch, not for 6.8 as it may be dangerous. I will also remove the RequestProcessor as it is useless and fix racecondition in cleanEmptyKeys() and findNonExcludedPackages() - non included in the patch.
Created attachment 91331 [details] PVC diff
rollback verified
Integrated into 'main-golden', will be available in build *200911191401* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main/rev/8497a06e01fd User: Milan Kubec <mkubec@netbeans.org> Log: #177110: empty packages visible in Projects view; rollback of #175997 fix