From: "Björn Steinbrink" <B.Steinbrink@gmx.de>
To: Thomas Leonard <talex5@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: Fwd: [Bug 163341] Re: git-svn gets wrong parent revision for tags
Date: Tue, 8 Apr 2008 19:15:02 +0200 [thread overview]
Message-ID: <20080408171502.GA6163@atjola.homenet> (raw)
In-Reply-To: <cd53a0140804080848r54bb1e6dq54b5cce62339d6d1@mail.gmail.com>
On 2008.04.08 16:48:03 +0100, Thomas Leonard wrote:
> Hi.
>
> The git-svn Ubuntu packager asked me to forward this here.
>
> Summary:
>
> When converting a subversion repository to GIT using git-svn, the tags
> do not have the right parent. Each tag should be identical to a trunk
> revision (which it was copied from), but because git-svn uses an
> earlier revision as the parent it appears that the same work was
> duplicated on two branches.
>
> Example:
>
> git-svn clone https://zero-install.svn.sourceforge.net/svnroot/zero-install
> -T trunk/0publish -r1890:2072 -b releases/0publish
>
> The git branch comes from r1894, yet the svn log shows that in
> includes files from r2070:
>
> $ svn log https://zero-install.svn.sourceforge.net/svnroot/zero-install
> -r2071 -v
> r2071 | tal197 | 2007-11-10 19:40:45 +0000 (Sat, 10 Nov 2007) | 1 line
> Changed paths:
> A /releases/0publish/0publish-0.12 (from /trunk/0publish:1968)
> R /releases/0publish/0publish-0.12/0publish (from
> /trunk/0publish/0publish:2070)
> R /releases/0publish/0publish-0.12/0publish.xml (from
> /trunk/0publish/0publish.xml:2070)
> R /releases/0publish/0publish-0.12/release.py (from
> /trunk/0publish/release.py:2069)
Well, SVN recorded useless, broken metadata.
SVN itself believes that the branch was created from revision 1968. As
that revision didn't introduce any changes to trunk/0publish, there's no
commit for that revision in the git branch, so git-svn took the most
recent one instead (1894).
For the other three files, SVN reports that the files were replaced by
versions from another branch. There's no immediate way to tell whether
those replacements make the branch equal to the more recent version of
trunk. So git-svn does it the safe way and reproduces what SVN told it
to reproduce: A commit that creates a branch and changes some files.
I guess sth. like this happened on the svn end:
svn cp trunk/0publish releases/0publish (at rev. 1968)
svn cp trunk/0publish/release.py releases/0publish (at rev. 2069)
...
svn commit (whenever)
So the branch was "incrementally" created locally and SVN decided to
record the "Uh, I copied this from here to there" metacrap^H^H^H^Hdata,
of which git-svn made use. Hooray for rename/copy tracking.
You could maybe ask for an enhancement so that git-svn tries to figure
out if the provided metadata is broken and looks up a matching revision
in such a case. But I guess it's not worth the trouble and could lead to
other breakage along the way...
Björn
next prev parent reply other threads:[~2008-04-08 17:15 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20071117143713.8355.50653.malonedeb@potassium.ubuntu.com>
[not found] ` <20080407195610.13681.39351.malone@potassium.ubuntu.com>
2008-04-08 15:48 ` Fwd: [Bug 163341] Re: git-svn gets wrong parent revision for tags Thomas Leonard
2008-04-08 17:15 ` Björn Steinbrink [this message]
2008-04-08 20:43 ` Thomas Leonard
2008-04-09 8:03 ` Björn Steinbrink
2008-04-09 10:39 ` Thomas Leonard
2008-04-09 11:28 ` Björn Steinbrink
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=20080408171502.GA6163@atjola.homenet \
--to=b.steinbrink@gmx.de \
--cc=git@vger.kernel.org \
--cc=talex5@gmail.com \
/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).