Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EGit / JGit » Cannot Open Compare Editor - This is a merge commit with more than one ancestor
Cannot Open Compare Editor - This is a merge commit with more than one ancestor [message #1828789] Thu, 18 June 2020 14:42 Go to next message
Albert Kao is currently offline Albert KaoFriend
Messages: 10
Registered: April 2016
Junior Member
This error screen popup when comparing with previous version.
error screen title : Cannot Open Compare Editor
error screen message : This is a merge commit with more than one ancestor

How to solve this issue?

Thanks.
Re: Cannot Open Compare Editor - This is a merge commit with more than one ancestor [message #1828814 is a reply to message #1828789] Fri, 19 June 2020 07:04 Go to previous messageGo to next message
Thomas Wolf is currently offline Thomas WolfFriend
Messages: 495
Registered: August 2016
Senior Member
More details needed.

  • Which EGit version?
  • How exactly are you trying to open the compare editor? (Which menu, where (in the package explorer? in an editor? in the history view?), what's the current selection?)


Current HEAD in your git repository seems to be at a merge commit.

In general, EGit cannot show the compare editor in this case since it doesn't know against which parent commit you want to compare. In some cases we might add something to let the user choose the parent commit to compare against, which is why I'd like to know what exactly you're doing.

A possible work-around with EGit 5.8.0 might be to select the merge commit and the parent commit wanted in the history view, then use "Show Unified Diff" from the context menu. To see a side-by-side diff of one file, use the link available on a hunk header (on the numbers in the @@ lines).
Re: Cannot Open Compare Editor - This is a merge commit with more than one ancestor [message #1828834 is a reply to message #1828814] Fri, 19 June 2020 14:20 Go to previous messageGo to next message
Albert Kao is currently offline Albert KaoFriend
Messages: 10
Registered: April 2016
Junior Member
version : m2e 1.9.1.20180912-1601 Eclipse Java EE IDE for Web Developers 2018-09 (4.9.0)
Steps to reproduce this error:
History View
Select any one file in a specific commit which is a merge commit with more than one ancestor.
Right click.
"Compare with Previous Version" option popup.
Click the "Compare with Previous Version" option.
This error screen popup when comparing with previous version.
error screen title : Cannot Open Compare Editor
error screen message : This is a merge commit with more than one ancestor

[Updated on: Fri, 19 June 2020 14:26]

Report message to a moderator

Re: Cannot Open Compare Editor - This is a merge commit with more than one ancestor [message #1828838 is a reply to message #1828834] Fri, 19 June 2020 15:55 Go to previous messageGo to next message
Thomas Wolf is currently offline Thomas WolfFriend
Messages: 495
Registered: August 2016
Senior Member
We might indeed ask the user at that point which parent he wants to compare against. Please open an enhancement request at https://bugs.eclipse.org/bugs/enter_bug.cgi?product=EGit .
Re: Cannot Open Compare Editor - This is a merge commit with more than one ancestor [message #1828854 is a reply to message #1828838] Sat, 20 June 2020 02:11 Go to previous message
Albert Kao is currently offline Albert KaoFriend
Messages: 10
Registered: April 2016
Junior Member
I open:
https://bugs.eclipse.org/bugs/show_bug.cgi?id=564493
Previous Topic:EGit signing somehow not accepted by GitLab, works fine for GitHub
Next Topic:Usage of ssh-agent
Goto Forum:
  


Current Time: Sat Oct 01 02:16:21 GMT 2022

Powered by FUDForum. Page generated in 0.01450 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top