Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 337198

Summary: Synchronize operation broken in 0.11.1
Product: [Technology] EGit Reporter: James Blackburn <jamesblackburn+eclipse>
Component: UIAssignee: Dariusz Luksza <dariusz.luksza>
Status: RESOLVED FIXED QA Contact:
Severity: major    
Priority: P3 CC: angvoz.dev, caniszczyk, dariusz.luksza, info, leachbj, matthias.sohn, remy.suen
Version: 0.11   
Target Milestone: ---   
Hardware: PC   
OS: Linux-GTK   
Whiteboard:

Description James Blackburn CLA 2011-02-15 05:54:11 EST
I've just installed egit 0.11.1:
  Eclipse EGit (Incubation)	0.11.1	org.eclipse.egit.feature.group
  Eclipse EGit - Source (Incubation)	0.11.1	org.eclipse.egit.source.feature.group
  Eclipse JGit (Incubation)	0.11.1	org.eclipse.jgit.feature.group
  Eclipse JGit - Source (Incubation)	0.11.1	org.eclipse.jgit.source.feature.group

and double clicking on 'Workspace Model' element in the synchronize view has no effect.

I can compare the files manually using the history view or the context menu in a resource view, but it doesn't work from the synchronize view. 

AFAICS this would make the Synchronize action useless in 0.11.1.
Comment 1 James Blackburn CLA 2011-02-15 05:54:53 EST
Note there are no errors logged to the error log. Double-click just fails silently for me.
Comment 2 Christian Trutz CLA 2011-02-15 06:47:36 EST
i see an ArrayIndexOutOfBoundsException

!ENTRY org.eclipse.ui 4 0 2011-02-15 12:32:56.954
!MESSAGE Unhandled event loop exception
!STACK 0
java.lang.ArrayIndexOutOfBoundsException: -1
	at java.util.ArrayList.get(ArrayList.java:324)
	at java.util.Collections$UnmodifiableList.get(Collections.java:1154)
	at org.eclipse.egit.ui.internal.synchronize.RemoteSelectionCombo.getValue(RemoteSelectionCombo.java:95)

in the log.
Comment 3 Remy Suen CLA 2011-02-15 07:17:20 EST
(In reply to comment #2)
> java.lang.ArrayIndexOutOfBoundsException: -1
>     at java.util.ArrayList.get(ArrayList.java:324)
>     at java.util.Collections$UnmodifiableList.get(Collections.java:1154)
>     at
> org.eclipse.egit.ui.internal.synchronize.RemoteSelectionCombo.getValue(RemoteSelectionCombo.java:95)

We have other bugs on this topic. See bug 322459 and bug 333063.
Comment 4 Dariusz Luksza CLA 2011-02-15 07:24:05 EST
I think that I know what could cause this problem.

Additionally this ArrayIndexOutOfBoundException isn't connected with this issue because it comes from "sync-dialog" not form showing compare editor.
Comment 5 Dariusz Luksza CLA 2011-02-15 07:35:44 EST
This patch should fix this issue:
http://egit.eclipse.org/r/2500
Comment 6 Chris Aniszczyk CLA 2011-02-15 10:12:33 EST
We will most likely spin a 0.11.3 for this one...
Comment 7 Bernard Leach CLA 2011-02-16 21:20:05 EST
(In reply to comment #1)
> Note there are no errors logged to the error log. Double-click just fails
> silently for me.

I have similar problems with synchronize.  Not sure if its the same issue but I have performed a sync of my local branch against the remote tracking branch.  The revision tree is something like;


A-C-D---G--H--J
 \   \    /  /
  B---E--F--I

My workspace points to I and a sync shows H and J (based on the commit IDs) which in reality are simple merge commits.

However J insteads shows my changes in I but also changes from G!  Double clicking on the individual files shows now differences between the files except for the files in I which show the differences correctly (well the actual differences from I but showing the commit IDs from H&J).

One of the entries also shows as 'Error: no label provider for ModelBlob[objecjtId=AnyObject[e97...'

The H changeset seems to do a similar thing, its showing changes from B,E and F.
Comment 8 Chris Aniszczyk CLA 2011-02-21 10:37:52 EST
Fixed in stable-0.11

(In reply to comment #7)

Can you open another bug for this case? Would be great if we could even get a test case :)
Comment 9 Dariusz Luksza CLA 2011-02-28 13:08:41 EST
*** Bug 336177 has been marked as a duplicate of this bug. ***