From: Michael Olson <mwolson@gnu.org>
To: Sam Vilain <sam@vilain.net>
Cc: git@vger.kernel.org, Eric Wong <normalperson@yhbt.net>,
Michael J Gruber <git@drmicha.warpmail.net>,
Tim Stoakes <tim@stoakes.net>
Subject: Re: [PATCH/RFC 2/2] git-svn: Don't allow missing commit parent to stop git-svn
Date: Wed, 21 Apr 2010 14:17:13 -0700 [thread overview]
Message-ID: <m2sc8b3bef91004211417n1f3368a7ica94a1c2a7656622@mail.gmail.com> (raw)
In-Reply-To: <1271880470.20208.47.camel@denix>
On Wed, Apr 21, 2010 at 1:07 PM, Sam Vilain <sam@vilain.net> wrote:
> On Tue, 2010-04-20 at 14:30 -0700, Michael Olson wrote:
>> Instead, fall back to assuming that the incoming merge is a bunch of
>> cherry-picks and ignore it.
>>
>> Signed-off-by: Michael W. Olson <mwolson@gnu.org>
>> ---
>> git-svn.perl | 2 +-
>> 1 files changed, 1 insertions(+), 1 deletions(-)
>>
>> diff --git a/git-svn.perl b/git-svn.perl
>> index 0e1feb3..1a53709 100755
>> --- a/git-svn.perl
>> +++ b/git-svn.perl
>> @@ -3110,7 +3110,7 @@ sub check_cherry_pick {
>> my %commits = map { $_ => 1 }
>> _rev_list("--no-merges", $tip, "--not", $base);
>> for my $range ( @ranges ) {
>> - delete @commits{_rev_list($range)};
>> + eval { delete @commits{_rev_list($range)} };
>> }
>> for my $commit (keys %commits) {
>> if (has_no_changes($commit)) {
>
> If the _rev_list here fails, it means it was passed in a bad range.
> This means that the calling code somehow ends up with a commit ID
> which doesn't exist. It's normally better to detect errors when
> they happen, not deeper into other functions when they break things...
Interestingly, I see people reporting the same problem in the thread
"git svn clone of subversion's own code failing". So it's not just
related to patch 1/2 of this series. At least that thread has a
public-facing repo so the problem should be easier to reproduce for a
real fix.
--
Michael Olson | http://mwolson.org/
next prev parent reply other threads:[~2010-04-21 21:17 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-20 21:30 [PATCH/RFC 2/2] git-svn: Don't allow missing commit parent to stop git-svn Michael Olson
2010-04-21 20:07 ` Sam Vilain
2010-04-21 21:17 ` Michael Olson [this message]
2010-04-21 23:45 ` [spf:guess,iffy,mismatch] " Sam Vilain
2010-04-28 15:51 ` Michael Olson
2010-05-03 21:19 ` Eric Wong
2010-05-04 6:40 ` Michael J Gruber
2010-05-04 18:34 ` Eric Wong
2010-05-04 22:02 ` Sam Vilain
2010-05-04 23:16 ` Eric Wong
2010-05-19 21:17 ` Michael Olson
2010-05-19 21:19 ` Michael Olson
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=m2sc8b3bef91004211417n1f3368a7ica94a1c2a7656622@mail.gmail.com \
--to=mwolson@gnu.org \
--cc=git@drmicha.warpmail.net \
--cc=git@vger.kernel.org \
--cc=normalperson@yhbt.net \
--cc=sam@vilain.net \
--cc=tim@stoakes.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).