Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix 2.26.0 rebase regression and documentation shortcoming #722

Closed
wants to merge 2 commits into from

Conversation

newren
Copy link
Contributor

@newren newren commented Mar 11, 2020

This two commit series addresses two points raised by Peff about rebase backend issues. The first is a two-line fix to a regression in 2.26.0 (when "the eighth batch for 2.26.0" added the dropping of commits which become empty, if the last commit in the series was the one that became empty the rebase would complete without cleaning out state files), and the other is just a documentation update about a backend difference that we were previously unaware of.

Changes since v1:

  • Clean out any MERGE_MSG file in addition to CHERRY_PICK_HEAD, and add a test

Cc: Phillip Wood phillip.wood123@gmail.com, Jeff King peff@peff.net, Junio C Hamano gitster@pobox.com

@newren
Copy link
Contributor Author

newren commented Mar 11, 2020

/submit

@gitgitgadget-git
Copy link

In commit e98c426 ("rebase (interactive-backend): fix handling of
commits that become empty", 2020-02-15), the merge backend was changed
to drop commits that did not start empty but became so after being
applied (because their changes were a subset of what was already
upstream).  This new code path did not need to go through the process of
creating a commit, since we were dropping the commit instead.
Unfortunately, this also means we bypassed the clearing of the
CHERRY_PICK_HEAD and MERGE_MSG files, which if there were no further
commits to cherry-pick would mean that the rebase would end but assume
there was still an operation in progress.  Ensure that we clear such
state files when we decide to drop the commit.

Signed-off-by: Elijah Newren <newren@gmail.com>
As noted by Junio:
    Back when "git am" was written, it was not considered a bug that the
    "git am --resolved" option did not offer the user a chance to update
    the log message to match the adjustment of the code the user made,
    but honestly, I'd have to say that it is a bug in "git am" in that
    over time it wasn't adjusted to the new world order where we
    encourage users to describe what they did when the automation
    hiccuped by opening an editor.  These days, even when automation
    worked well (e.g. a clean auto-merge with "git merge"), we open an
    editor.  The world has changed, and so should the expectations.

Junio also suggested providing a workaround such as allowing --no-edit
together with git rebase --continue, but that should probably be done in
a patch after the git-2.26.0 release.  For now, just document the known
difference in the Behavioral Differences section.

Signed-off-by: Elijah Newren <newren@gmail.com>
@dscho
Copy link
Member

dscho commented Mar 11, 2020

@emaste any idea why freebsd_12 is failing? It looks like it received signal 15 (SIGTERM?)?

@emaste
Copy link
Contributor

emaste commented Mar 11, 2020

There's an issue with FreeBSD VMs used by Cirrus at the moment it seems, see more details at cirruslabs/cirrus-ci-docs#592

We're trying to figure out what's happening.

You can try the rerun button on the Cirrus panel.

@newren
Copy link
Contributor Author

newren commented Mar 11, 2020

I'll ignore the FreeBSD one then and just submit...

@newren
Copy link
Contributor Author

newren commented Mar 11, 2020

/submit

@gitgitgadget-git
Copy link

@dscho
Copy link
Member

dscho commented Mar 11, 2020

You can try the rerun button on the Cirrus panel.

Right, I should have done that right away. That turned the build green.

@gitgitgadget-git
Copy link

This patch series was integrated into pu via 958a149.

@gitgitgadget-git
Copy link

This patch series was integrated into next via 52a3c30.

@gitgitgadget-git
Copy link

This branch is now known as en/rebase-backend.

@gitgitgadget-git
Copy link

This patch series was integrated into pu via b4f0038.

@gitgitgadget-git
Copy link

This patch series was integrated into next via b4f0038.

@gitgitgadget-git
Copy link

This patch series was integrated into master via b4f0038.

@gitgitgadget-git
Copy link

Closed via b4f0038.

@newren newren deleted the rebase-fixups branch March 24, 2020 23:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants