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

Bug 321502

Summary: Since 4b679b History View does not show branches and tags anymore
Product: [Technology] EGit Reporter: Stefan Lay <stefan.lay>
Component: UIAssignee: Matthias Sohn <matthias.sohn>
Status: RESOLVED FIXED QA Contact:
Severity: major    
Priority: P3 CC: matthias.sohn, sop
Version: unspecified   
Target Milestone: 0.9.0-M2   
Hardware: PC   
OS: All   
Whiteboard:

Description Stefan Lay CLA 2010-08-02 09:11:07 EDT
Since Commit 4b679bbef14d5b60fd74ae9123bd7690afb76ae1 (Remove Ref[] from SWTCommit constructor) no branches and tags are shown in the history view anymore.

Determination of branches and tags is now done in next() of PlotWalk. But this method is never called.
Comment 1 Stefan Lay CLA 2010-08-12 04:49:34 EDT
RevCommitList.fillTo() extracts the content out of the PlotWalk without calling next of PlotWalk. In instead uses RevWalk's internal mechanism with  a Generator. Therefore determination of branches and tags in next() of PlotWalk is never called.

How should this be fixed?
Comment 2 Stefan Lay CLA 2010-08-12 11:07:41 EDT
See http://dev.eclipse.org/mhonarc/lists/jgit-dev/msg00538.html for proposed solution.

Ina nutshell: Fix RevCommitList.fillTo() to use next() on the RevWalk
Comment 3 Shawn Pearce CLA 2010-08-12 19:49:10 EDT
Fixed by Change-Id Ic4bc49a0da90234271aea7c0a4e344a1c3620cfc
Comment 4 Matthias Sohn CLA 2010-08-13 05:54:37 EDT
http://egit.eclipse.org/r/#change,1299 doesn't fix bug 321502 since looking up
the list of refs to show in the history view implemented in PlotWalk.getTags(AnyObjectId)
fails to find the refs which are apparently in the list. We found that the failing
hashmap lookup ends up calling RevObject.equals() which does a pointer comparison
obviously failing to match the SWTCommit passed into PlotWalk.getTags(AnyObjectId)
with the keys of the hashmap returned by Repository.getAllRefsByPeeledObjectId().

Any hints how to fix this ? We are lost in polymorphia ...
Comment 5 Matthias Sohn CLA 2010-08-17 07:54:53 EDT
pushed http://egit.eclipse.org/r/#change,1313 to fix this
Comment 6 Chris Aniszczyk CLA 2010-08-24 17:12:14 EDT
This is fixed.