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 153795

Summary: revisions sorted from 0th to few first
Product: versioncontrol Reporter: matusdekanek <matusdekanek>
Component: MercurialAssignee: issues@versioncontrol <issues>
Status: VERIFIED FIXED    
Severity: blocker CC: sustaining
Priority: P2    
Version: 6.x   
Hardware: All   
OS: Linux   
Issue Type: DEFECT Exception Reporter:
Attachments: messages.log

Description matusdekanek 2008-11-24 16:23:59 UTC
When choosing revision number in some mercurial dialog, revisions are sorted in ascending order (so 0th revision is 
default, while HEAD revision might be unreachable if project has ~ 100 revisions).

steps to reproduce:
-create java application project
-initialize mercurial project on it
-create new class in project and commit it (or generally, make some changes in project and commit it)
-repeat previous step at least 6 times
-invoke versioning | revert action on project
    version 0 is set as default, versions 0-6 are listed in combo box for choosing revision, to which should be working 
copy reverted. When clicking on choice "fetch up to 20 revisions" also revision with higher numbers are shown in 
combobox. 
This means that, if project had about 100 revisions, HEAD revision would be unreachable (this is one reason why this is 
marked as P2).

Even bigger problem occurs after these steps
-clone project
-do some changes in cloned project and commit it (I created new class)
-do some changes in original project and commit it
-invoke versioning | share | pull from - default action on clone project
-answer 'no' on question whether to merge now
-invoke versioning | merge | merge changes action
-in combobox are revisions listed in ascending order (beginning with 0) and only revisions 0-6 (head revision should be 
now about 8-9). 
-Click on choice 'fetch up to 20 revisions'. In status bar will occur progres bar with label 'fetching revisions' which 
will never stop. 
That makes merging revisions higher than 6 impossible. This is second reason vhy P2.

(note that on other platforms or with other settings may combobox in mercurial revert and merge dialogs list more or 
less revisions by default, but that does not change this problem. either way there is problem with choosing higher 
revision number in these dialogs)

Both problems might cause inusability of mercurial plugin.

system configuration:
Product Version: NetBeans IDE Dev (Build 200811240201)
Java: 1.6.0_10; Java HotSpot(TM) Client VM 11.0-b15
System: Linux version 2.6.24-21-generic running on i386; UTF-8; en_US (nb)
I even heard of reproduction on windows machine.
Comment 1 matusdekanek 2008-11-24 16:24:41 UTC
Created attachment 74093 [details]
messages.log
Comment 2 Tomas Stupka 2009-01-09 08:53:47 UTC
fixed the wrong sort order. if the problem with the hanging merge dialog should still remain please file a separate issue.

changeset   : 113151:8ffdd94d5435
author      : Tomas Stupka <tstupka@netbeans.org>
date        : Fri Jan 09 09:50:35 CET 2009
summary     : #153795 - revisions sorted from 0th to few first
Comment 3 Quality Engineering 2009-01-11 06:34:12 UTC
Integrated into 'main-golden', will be available in build *200901110304* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/8ffdd94d5435
User: Tomas Stupka <tstupka@netbeans.org>
Log: #153795 - revisions sorted from 0th to few first
reverting the sort order
Comment 4 Peter Pis 2009-01-12 13:58:28 UTC
Verified.
Comment 5 rbalada 2009-01-15 15:26:50 UTC
I've backported the changeset http://hg.netbeans.org/main/rev/8ffdd94d5435 into release65_fixes repository as
http://hg.netbeans.org/release65_fixes/rev/138625dfc5ed
Comment 6 Peter Pis 2009-01-16 10:24:24 UTC
Verified in patch2.