Open
Conversation
where to branches are not able to fast forward anyways
|
👋 @IanLee1521 ! Any luck with this since your last update? Just ran into the same bug myself while working on a demo. |
Contributor
Author
|
I haven't, not, but I need to circle back and resolve this and a few other issues. Would be happy to take help over at: https://github.com/ianlee1521/visualizing-git/tree/gh-83-merge-no-ff to try to get to a final working PR though! |
udovicic
reviewed
Nov 10, 2018
| @@ -1416,15 +1416,21 @@ define(['d3'], function() { | |||
| throw new Error('Already up-to-date.'); | |||
| } else if (noFF === true) { | |||
| var branchStartCommit = this.getCommit(mergeTarget.parent); | |||
There was a problem hiding this comment.
Changing this, and following lines with:
var branchStartCommit = this.getCommit(mergeTarget.id);
var base = (currentCommit.isNoFFCommit === true) ? currentCommit.parent2 : null;
while (branchStartCommit.parent !== base && branchStartCommit.parent !== currentCommit.id) {
branchStartCommit = this.getCommit(branchStartCommit.parent);
}
will fix several issues, but unfortunately still does not work as expected in some edge cases. Hope this helps
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Work in progress at fixing #83
So far I have fixed the short case, but broken the previous working case...