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 248834 - java.lang.IllegalArgumentException: Comparison method violates its general contract! - when updating the libraries
Summary: java.lang.IllegalArgumentException: Comparison method violates its general co...
Status: RESOLVED FIXED
Alias: None
Product: javascript
Classification: Unclassified
Component: Libraries (show other bugs)
Version: 8.0.1
Hardware: PC Windows 7
: P3 normal (vote)
Assignee: Jan Stola
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-11-23 10:56 UTC by markiewb
Modified: 2015-01-03 13:13 UTC (History)
0 users

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 markiewb 2014-11-23 10:56:30 UTC
This error keeps coming up when loading the newly updated javascript libs from cdn while updating and adding libs in a HTML5 project.

java.lang.IllegalArgumentException: Comparison method violates its general contract!
	at java.util.TimSort.mergeHi(TimSort.java:868)
	at java.util.TimSort.mergeAt(TimSort.java:485)
	at java.util.TimSort.mergeCollapse(TimSort.java:410)
	at java.util.TimSort.sort(TimSort.java:214)
	at java.util.TimSort.sort(TimSort.java:173)
	at java.util.Arrays.sort(Arrays.java:659)
	at java.util.Collections.sort(Collections.java:217)
	at org.netbeans.modules.web.clientproject.api.jslibs.JavaScriptLibrarySelectionPanel$LibrariesTableModel$1.run(JavaScriptLibrarySelectionPanel.java:1270)
	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1423)
[catch] at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2033)


Product Version: NetBeans IDE 8.0.1 (Build 201408251540)
Updates: NetBeans IDE is updated to version NetBeans 8.0.1 Patch 1.1
Java: 1.7.0_65; Java HotSpot(TM) Client VM 24.65-b04
Runtime: Java(TM) SE Runtime Environment 1.7.0_65-b19
System: Windows 7 version 6.1 running on x86; Cp1252; en_US (nb)
User directory: C:\Users\mardonis\AppData\Roaming\NetBeans\8.0
Cache directory: C:\Users\mardonis\AppData\Local\NetBeans\Cache\8.0

Taken from here 
https://netbeans.org/bugzilla/show_bug.cgi?id=242547#c2
Comment 1 Jan Stola 2014-12-27 11:09:16 UTC
The support for CDNJS libraries has been rewritten (including the sorting algorithm) => I am marking this issue as fixed.
Comment 2 ocheja 2015-01-03 13:09:39 UTC
This issue still comes up in Netbeans 8.0.2.

I have just updated my Javascript library for the HTML5 module, the procedure I took are: Create new project > selected HTML5 > selected Cordova Application >named the project > selected Cordova Hello World > then clicked on the update link... the update was done successfully and I closed the window and tried creating a new project but when I get to the point where I clicked on the update link, the javascript library shows loading... and then I get this same error.
Comment 3 Jan Stola 2015-01-03 13:13:53 UTC
This issue is closed as fixed because CDNJS support is rewritten in the current development builds. This rewrite is not part of any release (including 8.0.2) yet.