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.

Bug 51781 - AIOOB from TreeView on multiple scenarios
Summary: AIOOB from TreeView on multiple scenarios
Status: CLOSED DUPLICATE of bug 51862
Alias: None
Product: platform
Classification: Unclassified
Component: Explorer (show other bugs)
Version: 4.x
Hardware: PC Windows XP
: P2 blocker (vote)
Assignee: Petr Nejedly
URL:
Keywords: RANDOM
: 53085 54154 56077 (view as bug list)
Depends on:
Blocks:
 
Reported: 2004-11-24 03:05 UTC by _ viendu
Modified: 2008-12-22 22:57 UTC (History)
4 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description _ viendu 2004-11-24 03:05:38 UTC
This is qbuild on the 11/02/2004.

When start up Netbeans, my project's node is not
expandable (just a single node, not a parent
node).  I close this project (not Netbeans). 
Next, I open the project again.  When open up, the
follow exception is thrown:

java.lang.ArrayIndexOutOfBoundsException: 8 >= 8
	at java.util.Vector.elementAt(Vector.java:432)
	at
javax.swing.tree.DefaultMutableTreeNode.getChildAt(DefaultMutableTreeNode.java:230)
	at
javax.swing.tree.VariableHeightLayoutCache.treeNodesChanged(VariableHeightLayoutCache.java:412)
	at
javax.swing.plaf.basic.BasicTreeUI$Handler.treeNodesChanged(BasicTreeUI.java:3600)
	at
javax.swing.tree.DefaultTreeModel.fireTreeNodesChanged(DefaultTreeModel.java:466)
	at
javax.swing.tree.DefaultTreeModel.nodesChanged(DefaultTreeModel.java:328)
	at
javax.swing.tree.DefaultTreeModel.nodeChanged(DefaultTreeModel.java:261)
	at
org.openide.explorer.view.NodeTreeModel$Listener.update(NodeTreeModel.java:160)
	at
org.openide.explorer.view.VisualizerNode.run(VisualizerNode.java:368)
	at org.openide.util.Mutex.readAccess(Mutex.java:243)
[catch] at
org.openide.explorer.view.VisualizerNode.run(VisualizerNode.java:351)
	at
java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
	at
java.awt.EventQueue.dispatchEvent(EventQueue.java:461)
	at
java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:234)
	at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
	at
java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157)
	at
java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149)
	at
java.awt.EventDispatchThread.run(EventDispatchThread.java:110)
Comment 1 Petr Nejedly 2005-01-07 15:57:19 UTC
*** Issue 53085 has been marked as a duplicate of this issue. ***
Comment 2 _ pkuzel 2005-01-10 09:23:00 UTC
It's not so random. In Revision explorer you can get it quite often
when removing files. Visually it leaves gaps in the tree.
Comment 3 Jan Chalupa 2005-01-29 17:15:00 UTC
*** Issue 54154 has been marked as a duplicate of this issue. ***
Comment 4 Jan Chalupa 2005-01-29 17:29:37 UTC
It seems to occur quite frequently.
Comment 5 Petr Nejedly 2005-03-10 12:12:56 UTC
*** Issue 56077 has been marked as a duplicate of this issue. ***
Comment 6 Petr Nejedly 2005-03-10 12:16:10 UTC
Seems that it is still happening (latest report from build 200503061900) even
after all the fixes to visualizers.

Looks like if somebody is modifying children without holding write on Children.MUTEX

I'll try to add few asserts...
Comment 7 Petr Nejedly 2005-04-05 14:25:30 UTC
Will probably be fixed by fixing issue 51862 so still keeping TM=4.1
Comment 8 Peter Lam 2005-04-05 20:48:00 UTC
The exception is still happening to me in buzz milestone build #5. Here's my
reproducible steps.

1. invoke ide
2. create a java project on existing java sources (I use the JSE tutorial sample
named BankPack for existing sources)
3. create uml reverse engineering project & select the java project created from
step 2 to do reverse engineering
4. from the project explorer tab, expand the uml project and modeling nodes and
the nodes containing the uml class elements created from step 3
==>> From here, clicking on any class element will result in NPE. Closing and
reopening the uml project leaves the model node and diagram node empty. Shutting
down and restarting the ide solves the problem and the NPE does not exist.
Comment 9 Petr Nejedly 2005-04-05 21:02:47 UTC
> The exception is still happening to me in buzz milestone build #5.
Sure, I know. I use it as a reoroducible test case and have a fix already, it seems.

> will result in NPE
Now I don't know what you're talking about, this is about AIOOB and I'm able to
reproduce that AIOOB using UML cluster from buzz.
Comment 10 pcmreddy 2005-04-06 17:42:21 UTC
This bug fix is requested by JSE team. Exceptions needs to be handled properly.
Marking this bug as P1.
Comment 11 Petr Nejedly 2005-04-07 10:16:19 UTC
1) Not P1. No dataloss.
2) I still haven't got your NPE stack trace
3) The bug is already partially fixed in trunk, see issue 51862.
  I wanted to keep them separated as they are slightly different, but some
  people don't understand...

4) The problem is in fact on JSE side. Tell the JSE team that their nodes should
not be equal() (some of your nodes are equals() yet they don't provide the same
hashcode, so their contract is in fact broken)



*** This issue has been marked as a duplicate of 51862 ***
Comment 12 Tomas Danek 2005-07-14 16:39:47 UTC
In fact, i'm not realy sure this is dup. But this seems to be fixed in 4.2
dailybuilds, so I'm leaving some time before I'll close this.