[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

RE: Re: More Merge Bad Behavior (with experimental results)

From: Bob Archer <Bob.Archer_at_amsi.com>
Date: Mon, 17 Nov 2008 14:55:01 -0500

I'm curious... did you run svnadmin upgrade and
svn-populate-node-origina-index on your repository when you moved from
1.4 to 1.5 on the server? Also, you probably want to upgrade your server
to 1.5.4. Some merging bugs were fixed in .2,.3,.4.

Bob

-----Original Message-----
From: Rush Manbert [mailto:rush_at_manbert.com]
Sent: Monday, November 17, 2008 2:12 PM
To: subversion
Subject: Re: More Merge Bad Behavior (with experimental results)

On Nov 14, 2008, at 2:44 PM, Rush Manbert wrote:

> I posted a few days ago about my problems merging either to a branch
> from the trunk or from that branch back to the trunk.
>
> Now a colleague is seeing the same problem.
>
> He copied the trunk to a branch 3 days ago. We have been making
> changes on the branch since then, and now we're finished. In the
> meantime, some non-overlapping changes happened in the trunk. Now he
> wants to merge the branch back into the trunk. Since he never needed
> to synch changes in the trunk by merging, we don't need to do a
> reintegration merge, so he tried this:
> * Check out the trunk to ~/trunk_merge
> * cd ~/trunk_merge
> * svn merge URL_TO_BRANCH
>
> Svn thinks about this for a while, then says it wants to merge
> revision 2 through 1633 to the WC. The branch was created at
> revision 1634.
>
> This wants to do all sorts of crazy stuff, so we killed it, ran svn
> revert -R ., then svn stat to be sure we had a pristine WC.
>
> Then we tried this merge command:
> svn merge URL_TO_BRANCH -r1634:head --dry-run
>
> The output from this looks like it would do the right thing.
>
> This is the second time now that the merge wants to merge everything
> from the beginning of the world (rev 2) through the revision just
> before the branch was created (rev 1633), and we don't understand
> why this is happening. We thought Subversion 1.5 was supposed to
> track the revisions correctly so that this would work without
> needing us to specify the revisions.
>
> We are running the 1.5.1 client, and the server is running 1.5.0. We
> created both branches using SmartSVN 4, which is a SVN 1.5-compliant
> client.
>
> We have also done a very similar merge in the past (2 months ago),
> and it worked as expected.
>
> We're sort of at a loss here. My colleague suspects there is
> something wrong with our repository. I said I would post again and
> see if any of the experts had some advice. Something we can look at
> on the repository, or the branch, or ??? Any guidance would be
> appreciated.
>
> - Rush

I have done some experimentation, both with a brand new repository and
with our existing repository.
I did the following test:

1) Make a new repository using svnadmin 1.5.1 on my local machine
2) Populate the trunk
3) Copy trunk to a branch using command line svn 1.5.1
4) Copy trunk to a different branch using SmartSVN 4.0.9
5) Make some changes to the trunk
6) Make identical changes to both branches
7) Commit all changes

I can branch from the trunk to either branch (using --dry-run so that
nothing really happens), or from either branch to the trunk, and the
revisions that are shown are correct. So a new repository acts as
expected.

I then tried this test with our current repository:
1) Created a new sibling of trunk, which I called testTrunk in the
repository on the server
2) Populated testTrunk with the same import tree that I used for the
new repository test
3) Copied testTrunk to a branch using command line svn (The server is
running 1.5.0)
4) Copied testTrunk to a different branch using SmartSVN 4.0.9
5) Made some changes to testTrunk
6) Made identical changes to both of my testTrunk branches.
7) Committed all changes

testTrunk Revisions of interest:
        Created....: 1667
        Populated..: 1668
        Last Commit: 1671

SmartSvn Branch Revisions of interest:
        Created....: 1669
        Last Commit: 1672

Cmd Line Svn Branch Revisions of interest:
        Created....: 1670
        Last Commit: 1673

Since this is the working repository, our current revision is 1677 and
revisions 1674 through 1677 all happened in trunk.

-------------------------------------------------------
* Try to merge from testTrunk to Smart Svn Branch says:
--- Merging r1668 through r1677 into '.':

I would expect something like 1669 through 1671, or maybe 1670 through
1671, or 1670 through 1677, or 1671 all by itself, but certainly not a
starting revision that is older than the branch.

-------------------------------------------------------
* Try to merge from testTrunk to Cmd Line Svn Branch says:
--- Merging r1668 through r1677 into '.':

Again, it seems wrong that the start revision is older than the branch.

-------------------------------------------------------
* Try to merge from Smart Svn Branch to testTrunk says:
--- Merging r1668 into '.':
--- Merging r1669 through r1677 into '.':

Shouldn't this be the range 1670 through 1672? Or maybe just 1672 (the
only commit on this branch)?

-------------------------------------------------------
* Try to merge from Cmd Line Svn Branch to testTrunk says:
--- Merging r1668 through r1669 into '.':
--- Merging r1670 through r1677 into '.':

Same here. I would expect 1671 through 1673, or maybe just 1673.

These tests have convinced me of 2 things:
1) SmartSVN has nothing to do with our merge problems.
2) Something appears to be wrong with our repository metadata.

Am I crazy here, or does this look wrong to the gurus? If you agree
that something seems to be wrong, are there any suggestions about how
I can fix it?

Thanks,
Rush

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: users-help_at_subversion.tigris.org

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: users-help_at_subversion.tigris.org
Received on 2008-11-17 20:55:44 CET

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.