From: Phillip Wood <phillip.wood123@gmail.com>
To: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>,
phillip.wood@dunelm.org.uk
Cc: git@vger.kernel.org, Stephan Beyer <s-beyer@gmx.net>,
Johannes Schindelin <johannes.schindelin@gmx.de>
Subject: Re: [PATCH] sequencer: update abort safety file more sparingly
Date: Sun, 3 Sep 2023 20:48:14 +0100 [thread overview]
Message-ID: <fdf80c36-0e28-44f3-9cef-85d38d2d48f1@gmail.com> (raw)
In-Reply-To: <ZPTdmnHfDcTBqaSl@ugly>
On 03/09/2023 20:25, Oswald Buddenhagen wrote:
> On Sun, Sep 03, 2023 at 07:40:00PM +0100, Phillip Wood wrote:
>> On 03/09/2023 16:11, Oswald Buddenhagen wrote:
>>> The only situation where the file's content matters is --continue'ing
>>> (after a multi-cherry-pick merge conflict).
>>
>> I don't think "cherry-pick --continue" consults the abort safety file,
> duh, obvious blunder.
>
>> it only matters for "cherry-pick --skip"
>>
> that doesn't seem right. a --skip is just a --continue with a prior
> reset, more or less.
sequencer_skip() calls rollback_is_safe() which checks the abort safety
file.
>> and "cherry-pick --abort".
>>
> that one, of course.
>
>>> This means that it is
>>> sufficient to write it in a single place, when we are prematurely
>>> exiting the main workhorse.
>>
>> I think this introduces a regression because the safety file will not
>> get updated when "cherry-pick --continue" stops for the user to
>> resolve conflicts.
>>
> true, there is indeed this second entry point.
> i'll try to find a better "choke point".
I think that is probably tricky, I'm not really clear what the
aim/purpose of this refactoring is.
>>> which wasn't even reliable: a single pick executed during an
>>> interrupted sequence would bypass the safety.
>>
>> An alternate view is that the abort safety file exists to prevent the
>> user losing commits that have not been cherry-picked and it is
>> desirable to be able to abort after cherry-picking a single pick in
>> the middle of a sequence of cherry-picks.
>>
> if you did a fresh commit before or after the single pick, you'd lose it.
> also,
Oh, I can see that you'd lose a commit made before a single pick but I
don't see how you'd lose a commit made after it. I'm still not convinced
it is a particularly helpful change.
> the feature doesn't actually prevent aborting, only the automatic
> reset.
Oh right, it removes the state directory but leaves HEAD untouched if it
does not match the commit recorded in the abort safety file.
Best Wishes
Phillip
> regards
next prev parent reply other threads:[~2023-09-03 19:48 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-03 15:11 [PATCH] sequencer: update abort safety file more sparingly Oswald Buddenhagen
2023-09-03 18:40 ` Phillip Wood
2023-09-03 19:25 ` Oswald Buddenhagen
2023-09-03 19:48 ` Phillip Wood [this message]
2023-09-03 20:18 ` Oswald Buddenhagen
2023-09-04 10:05 ` Phillip Wood
2023-09-04 12:48 ` Oswald Buddenhagen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=fdf80c36-0e28-44f3-9cef-85d38d2d48f1@gmail.com \
--to=phillip.wood123@gmail.com \
--cc=git@vger.kernel.org \
--cc=johannes.schindelin@gmx.de \
--cc=oswald.buddenhagen@gmx.de \
--cc=phillip.wood@dunelm.org.uk \
--cc=s-beyer@gmx.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).