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 205348

Summary: IllegalArgumentException: Comparison method violates its general contract!
Product: platform Reporter: turneliusz
Component: Outline&TreeTableAssignee: Martin Entlicher <mentlicher>
Status: RESOLVED FIXED    
Severity: normal    
Priority: P3    
Version: 7.1   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter: 183040
Attachments: stacktrace

Description turneliusz 2011-11-21 11:30:34 UTC
Build: NetBeans IDE Dev (Build 201111160600)
VM: Java HotSpot(TM) 64-Bit Server VM, 21.1-b02, Java(TM) SE Runtime Environment, 1.7.0_01-b08
OS: Windows 7

User Comments:
turneliusz: Debugging




Stacktrace: 
java.lang.IllegalArgumentException: Comparison method violates its general contract!
   at java.util.TimSort.mergeHi(TimSort.java:0)
   at java.util.TimSort.mergeAt(TimSort.java:0)
   at java.util.TimSort.mergeForceCollapse(TimSort.java:0)
   at java.util.TimSort.sort(TimSort.java:0)
   at java.util.TimSort.sort(TimSort.java:0)
   at java.util.Arrays.sort(Arrays.java:0)
Comment 1 turneliusz 2011-11-21 11:30:36 UTC
Created attachment 113363 [details]
stacktrace
Comment 2 Martin Entlicher 2011-11-21 13:10:23 UTC
We need some steps to reproduce this.
Unfortunately the exception message is absolutely insufficient. It should tell us what is the comparator and which comparisons in particular violate the contract.

Since we do not have such information, please provide steps how can we reproduce the exception.
Comment 3 turneliusz 2011-11-21 13:48:19 UTC
It will be almost impossible for me to reproduce it. This was while doing regular tasks in IDE so if the trace is not enough I will wait to see this error happening again.
Comment 4 Martin Entlicher 2011-11-21 14:18:44 UTC
O.K. Thanks.
Do you remember which column in which debugger view did you have sorted when this exception occurred?

I have a suspicion that ETableColumn.RowComparator is problematic. I'll add some debug messages into trunk around the sort call so that we can get more information...
Comment 5 turneliusz 2011-11-21 14:33:02 UTC
I think it was "variables" and sorted by "value" ASC
Comment 6 Martin Entlicher 2012-01-02 13:13:16 UTC
This should be fixed together with issue #205828.