From: "Björn Steinbrink" <B.Steinbrink@gmx.de>
To: Jeff King <peff@peff.net>
Cc: Clemens Buchacher <drizzd@aon.at>,
Jeffrey Middleton <jefromi@gmail.com>,
Michael J Gruber <git@drmicha.warpmail.net>,
git@vger.kernel.org
Subject: Re: git update --prune issue
Date: Wed, 28 Oct 2009 00:30:56 +0100 [thread overview]
Message-ID: <20091027233056.GA25689@atjola.homenet> (raw)
In-Reply-To: <20091027184627.GA19292@sigill.intra.peff.net>
On 2009.10.27 14:46:27 -0400, Jeff King wrote:
> On Tue, Oct 27, 2009 at 12:50:55PM -0400, Jeff King wrote:
>
> > > Actually, it's beta_gc_dev_old and beta_gc_dev, not the same refs.
> >
> > OK, I'm a bit blind. Thanks for pointing it out. I'll still see if I can
> > replicate it.
>
> I'm not having any luck reproducing here with a simple case. :( I'm
> trying:
You need more parent repos, and you need packs. What I guess what
happens is:
The first remote gets fetched from.
The first remote gets pruned. This initializes the pack stuff.
The second remote gets fetched from, and creates a _new_ _pack_.
The second remote gets pruned (*)
The third remote gets fetched from.
The third remote gets pruned.
Now, this prune step calls for_each_ref, which looks through the new
refs for the second remote. This fails, because the new pack was not
present when the pack "system" got initialzed.
(*) I have no idea why this step doesn't fail... But hey, I have no idea
about the whole pack handling either. I just recall that there's some
initialization step...
This reproduces the issue here:
#!/bin/sh
rm -rf parent* child
commit() {
echo $1 >file && git add file && git commit -m $1
}
mkdir parent0 && (
cd parent0 &&
git init &&
commit one
) &&
mkdir parent1 && (
cd parent1 &&
git init &&
commit two &&
commit three &&
git checkout -b other
) &&
mkdir parent2 && (
cd parent2 &&
git init &&
commit four
) &&
mkdir child && (
cd child &&
git init &&
git config fetch.unpackLimit 1
git remote add parent0 file://$PWD/../parent0 &&
git remote add parent1 file://$PWD/../parent1 &&
git remote add parent2 file://$PWD/../parent2 &&
git remote update
) && (
cd parent1 &&
git checkout master &&
git branch -d other &&
git reset --hard HEAD^ &&
commit five
) && (
cd child &&
git remote update --prune
)
prev parent reply other threads:[~2009-10-27 23:31 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-10-26 22:08 git update --prune issue Jeffrey Middleton
2009-10-27 8:42 ` Michael J Gruber
2009-10-27 15:07 ` Jeffrey Middleton
2009-10-27 16:29 ` Jeff King
2009-10-27 16:39 ` Jeffrey Middleton
2009-10-27 16:40 ` Clemens Buchacher
2009-10-27 16:50 ` Jeff King
2009-10-27 18:46 ` Jeff King
2009-10-27 23:30 ` Björn Steinbrink [this message]
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=20091027233056.GA25689@atjola.homenet \
--to=b.steinbrink@gmx.de \
--cc=drizzd@aon.at \
--cc=git@drmicha.warpmail.net \
--cc=git@vger.kernel.org \
--cc=jefromi@gmail.com \
--cc=peff@peff.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).