You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Paul Burba <pt...@gmail.com> on 2009/04/09 14:40:04 UTC

RFC: Make default depth of merge infinity

Currently (trunk@37129) the default depth of a merge is the depth of
the merge target.  If the target has children that are at a deeper
depth then those children are not merged to.

For example, say we have this merge target:

  branch/            (depth == immediates)
  branch/notes/      (depth == empty)
  branch/src/        (depth == infinity)
  branch/README.TXT  (depth N/A)

If we merge with no depth option specified the merge will not merge
any applicable changes into branch/src/*.

Several people find this a bit counter-intuitive, and I agree:

http://svn.haxx.se/dev/archive-2009-03/0701.shtml

This can be worked around by passing --depth=infinity to the merge
subcommand, but I doubt many users will realize this.

Also, this is inconsistent with how update works.  In the above
example if we update branch with no --depth or --set-depth option then
branch/src/* would get any available updates.

I'd like to change merge's default depth to infinity.  Any objections
or thoughts?

Paul

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1614711

Re: RFC: Make default depth of merge infinity

Posted by Paul Burba <pt...@gmail.com>.
On Thu, Apr 9, 2009 at 11:07 AM, David Ferguson
<fe...@gmail.com> wrote:
> As heavy users of sparse checkouts and merging, my users and I get bit by
> this confusion all the time.  Users either don't understand why something
> they expected isn't getting merged in or they think they have merged
> everything but in fact they merged incompletely because of their sparse
> checkout.
>
> I would very much appreciate it if the default were changed to infinity.
>
> On Thu, Apr 9, 2009 at 10:40 AM, Paul Burba <pt...@gmail.com> wrote:
>>
>> Currently (trunk@37129) the default depth of a merge is the depth of
>> the merge target.  If the target has children that are at a deeper
>> depth then those children are not merged to.
>>
>> For example, say we have this merge target:
>>
>>  branch/            (depth == immediates)
>>  branch/notes/      (depth == empty)
>>  branch/src/        (depth == infinity)
>>  branch/README.TXT  (depth N/A)
>>
>> If we merge with no depth option specified the merge will not merge
>> any applicable changes into branch/src/*.
>>
>> Several people find this a bit counter-intuitive, and I agree:
>>
>> http://svn.haxx.se/dev/archive-2009-03/0701.shtml
>>
>> This can be worked around by passing --depth=infinity to the merge
>> subcommand, but I doubt many users will realize this.
>>
>> Also, this is inconsistent with how update works.  In the above
>> example if we update branch with no --depth or --set-depth option then
>> branch/src/* would get any available updates.
>>
>> I'd like to change merge's default depth to infinity.  Any objections
>> or thoughts?

One unintended consequence of making this change:

Given my previous example:

  branch/            (depth == immediates)
  branch/notes/      (depth == empty)
  branch/src/        (depth == infinity)
  branch/README.TXT  (depth N/A)

If we merge rN from 'trunk', and rN includes a change to
'trunk/notes/README', there will now be a tree conflict on
'branch/notes' of the 'local delete, incoming edit upon merge' flavor.

So we will trade one unexpected behavior, not merging into infinite
depth children, for potentially another unexpected behavior, trying to
merge into sparse children.  The latter situation is preferable IMO
because you can't commit without addressing the tree conflicts.  In
the former (i.e. current) situation you could easily commit thinking
there were no changes to your missing children when in fact there
were.  I don't think this is any reason not to make the proposed
change, but wanted to throw it out there if anybody disagrees.

Paul

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1629751


Re: RFC: Make default depth of merge infinity

Posted by David Ferguson <fe...@gmail.com>.
As heavy users of sparse checkouts and merging, my users and I get bit by
this confusion all the time.  Users either don't understand why something
they expected isn't getting merged in or they think they have merged
everything but in fact they merged incompletely because of their sparse
checkout.

I would very much appreciate it if the default were changed to infinity.



On Thu, Apr 9, 2009 at 10:40 AM, Paul Burba <pt...@gmail.com> wrote:

> Currently (trunk@37129) the default depth of a merge is the depth of
> the merge target.  If the target has children that are at a deeper
> depth then those children are not merged to.
>
> For example, say we have this merge target:
>
>  branch/            (depth == immediates)
>  branch/notes/      (depth == empty)
>  branch/src/        (depth == infinity)
>  branch/README.TXT  (depth N/A)
>
> If we merge with no depth option specified the merge will not merge
> any applicable changes into branch/src/*.
>
> Several people find this a bit counter-intuitive, and I agree:
>
> http://svn.haxx.se/dev/archive-2009-03/0701.shtml
>
> This can be worked around by passing --depth=infinity to the merge
> subcommand, but I doubt many users will realize this.
>
> Also, this is inconsistent with how update works.  In the above
> example if we update branch with no --depth or --set-depth option then
> branch/src/* would get any available updates.
>
> I'd like to change merge's default depth to infinity.  Any objections
> or thoughts?
>
> Paul
>
> ------------------------------------------------------
>
> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1614711
>

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1615121

Re: RFC: Make default depth of merge infinity

Posted by Paul Burba <pt...@gmail.com>.
On Thu, Apr 9, 2009 at 10:56 AM, Mark Phippard <ma...@gmail.com> wrote:
> On Thu, Apr 9, 2009 at 10:40 AM, Paul Burba <pt...@gmail.com> wrote:
>> Currently (trunk@37129) the default depth of a merge is the depth of
>> the merge target.  If the target has children that are at a deeper
>> depth then those children are not merged to.
>>
>> For example, say we have this merge target:
>>
>>  branch/            (depth == immediates)
>>  branch/notes/      (depth == empty)
>>  branch/src/        (depth == infinity)
>>  branch/README.TXT  (depth N/A)
>>
>> If we merge with no depth option specified the merge will not merge
>> any applicable changes into branch/src/*.
>>
>> Several people find this a bit counter-intuitive, and I agree:
>>
>> http://svn.haxx.se/dev/archive-2009-03/0701.shtml
>>
>> This can be worked around by passing --depth=infinity to the merge
>> subcommand, but I doubt many users will realize this.
>>
>> Also, this is inconsistent with how update works.  In the above
>> example if we update branch with no --depth or --set-depth option then
>> branch/src/* would get any available updates.
>>
>> I'd like to change merge's default depth to infinity.  Any objections
>> or thoughts?
>
> +1
>
> Not to hijack this, but there are other depth problems lurking.  For
> example, using your above example, this command:
>
> svn update --set-depth=infinity branches
>
> Does not change the depth of any of the children of branches to
> infinity.

Hmmm, I can't replicate this with trunk.  What version did you see it with?

> I cannot imagine anyone thinks that is the right behavior.
>
>
> --
> Thanks
>
> Mark Phippard
> http://markphip.blogspot.com/
>

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1615531


Re: RFC: Make default depth of merge infinity

Posted by Paul Burba <pt...@gmail.com>.
On Fri, Apr 10, 2009 at 4:25 PM, Paul Burba <pt...@gmail.com> wrote:
> On Fri, Apr 10, 2009 at 9:21 AM, Paul Burba <pt...@gmail.com> wrote:
>> On Fri, Apr 10, 2009 at 8:42 AM, Bert Huijben <be...@qqmail.nl> wrote:
>>>
>>>
>>>> -----Original Message-----
>>>> From: Mark Phippard [mailto:markphip@gmail.com]
>>>> Sent: donderdag 9 april 2009 16:56
>>>> To: Paul Burba
>>>> Cc: dev@subversion.tigris.org
>>>> Subject: Re: RFC: Make default depth of merge infinity
>>>>
>>>> On Thu, Apr 9, 2009 at 10:40 AM, Paul Burba <pt...@gmail.com> wrote:
>>>> > Currently (trunk@37129) the default depth of a merge is the depth of
>>>> > the merge target.  If the target has children that are at a deeper
>>>> > depth then those children are not merged to.
>>>> >
>>>> > For example, say we have this merge target:
>>>> >
>>>> >  branch/            (depth == immediates)
>>>> >  branch/notes/      (depth == empty)
>>>> >  branch/src/        (depth == infinity)
>>>> >  branch/README.TXT  (depth N/A)
>>>> >
>>>> > If we merge with no depth option specified the merge will not merge
>>>> > any applicable changes into branch/src/*.
>>>> >
>>>> > Several people find this a bit counter-intuitive, and I agree:
>>>> >
>>>> > http://svn.haxx.se/dev/archive-2009-03/0701.shtml
>>>> >
>>>> > This can be worked around by passing --depth=infinity to the merge
>>>> > subcommand, but I doubt many users will realize this.
>>>> >
>>>> > Also, this is inconsistent with how update works.  In the above
>>>> > example if we update branch with no --depth or --set-depth option then
>>>> > branch/src/* would get any available updates.
>>>> >
>>>> > I'd like to change merge's default depth to infinity.  Any objections
>>>> > or thoughts?
>>>>
>>>> +1
>>>
>>> +1. Please, make it explicit if you don't want to use a recursive merge.
>>
>> No disagreement, so I made the change in r37156.  We still have the
>> issue Mark mentioned to deal with...
>
> Ugh, a lot of analysis for such a simple fix!  But fixed it is,
> r37169.  Now if we update --set-depth a WC which  has shallow
> subtrees, those subtrees get added and get their depths properly set
> to infinity.

fyi: Nominated both r37156 and r37169 for backport to the 1.5.x and
1.6.x branches.

Paul

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1691340


Re: RFC: Make default depth of merge infinity

Posted by Paul Burba <pt...@gmail.com>.
On Fri, Apr 10, 2009 at 9:21 AM, Paul Burba <pt...@gmail.com> wrote:
> On Fri, Apr 10, 2009 at 8:42 AM, Bert Huijben <be...@qqmail.nl> wrote:
>>
>>
>>> -----Original Message-----
>>> From: Mark Phippard [mailto:markphip@gmail.com]
>>> Sent: donderdag 9 april 2009 16:56
>>> To: Paul Burba
>>> Cc: dev@subversion.tigris.org
>>> Subject: Re: RFC: Make default depth of merge infinity
>>>
>>> On Thu, Apr 9, 2009 at 10:40 AM, Paul Burba <pt...@gmail.com> wrote:
>>> > Currently (trunk@37129) the default depth of a merge is the depth of
>>> > the merge target.  If the target has children that are at a deeper
>>> > depth then those children are not merged to.
>>> >
>>> > For example, say we have this merge target:
>>> >
>>> >  branch/            (depth == immediates)
>>> >  branch/notes/      (depth == empty)
>>> >  branch/src/        (depth == infinity)
>>> >  branch/README.TXT  (depth N/A)
>>> >
>>> > If we merge with no depth option specified the merge will not merge
>>> > any applicable changes into branch/src/*.
>>> >
>>> > Several people find this a bit counter-intuitive, and I agree:
>>> >
>>> > http://svn.haxx.se/dev/archive-2009-03/0701.shtml
>>> >
>>> > This can be worked around by passing --depth=infinity to the merge
>>> > subcommand, but I doubt many users will realize this.
>>> >
>>> > Also, this is inconsistent with how update works.  In the above
>>> > example if we update branch with no --depth or --set-depth option then
>>> > branch/src/* would get any available updates.
>>> >
>>> > I'd like to change merge's default depth to infinity.  Any objections
>>> > or thoughts?
>>>
>>> +1
>>
>> +1. Please, make it explicit if you don't want to use a recursive merge.
>
> No disagreement, so I made the change in r37156.  We still have the
> issue Mark mentioned to deal with...

Ugh, a lot of analysis for such a simple fix!  But fixed it is,
r37169.  Now if we update --set-depth a WC which  has shallow
subtrees, those subtrees get added and get their depths properly set
to infinity.

Paul

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1635447


Re: RFC: Make default depth of merge infinity

Posted by Paul Burba <pt...@gmail.com>.
On Fri, Apr 10, 2009 at 8:42 AM, Bert Huijben <be...@qqmail.nl> wrote:
>
>
>> -----Original Message-----
>> From: Mark Phippard [mailto:markphip@gmail.com]
>> Sent: donderdag 9 april 2009 16:56
>> To: Paul Burba
>> Cc: dev@subversion.tigris.org
>> Subject: Re: RFC: Make default depth of merge infinity
>>
>> On Thu, Apr 9, 2009 at 10:40 AM, Paul Burba <pt...@gmail.com> wrote:
>> > Currently (trunk@37129) the default depth of a merge is the depth of
>> > the merge target.  If the target has children that are at a deeper
>> > depth then those children are not merged to.
>> >
>> > For example, say we have this merge target:
>> >
>> >  branch/            (depth == immediates)
>> >  branch/notes/      (depth == empty)
>> >  branch/src/        (depth == infinity)
>> >  branch/README.TXT  (depth N/A)
>> >
>> > If we merge with no depth option specified the merge will not merge
>> > any applicable changes into branch/src/*.
>> >
>> > Several people find this a bit counter-intuitive, and I agree:
>> >
>> > http://svn.haxx.se/dev/archive-2009-03/0701.shtml
>> >
>> > This can be worked around by passing --depth=infinity to the merge
>> > subcommand, but I doubt many users will realize this.
>> >
>> > Also, this is inconsistent with how update works.  In the above
>> > example if we update branch with no --depth or --set-depth option then
>> > branch/src/* would get any available updates.
>> >
>> > I'd like to change merge's default depth to infinity.  Any objections
>> > or thoughts?
>>
>> +1
>
> +1. Please, make it explicit if you don't want to use a recursive merge.

No disagreement, so I made the change in r37156.  We still have the
issue Mark mentioned to deal with, but we can deal with that in a
separate thread.

Paul

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1630739


RE: RFC: Make default depth of merge infinity

Posted by Bert Huijben <rh...@sharpsvn.net>.
> -----Original Message-----
> From: Mark Phippard [mailto:markphip@gmail.com]
> Sent: donderdag 9 april 2009 16:56
> To: Paul Burba
> Cc: dev@subversion.tigris.org
> Subject: Re: RFC: Make default depth of merge infinity
> 
> On Thu, Apr 9, 2009 at 10:40 AM, Paul Burba <pt...@gmail.com> wrote:
> > Currently (trunk@37129) the default depth of a merge is the depth of
> > the merge target.  If the target has children that are at a deeper
> > depth then those children are not merged to.
> >
> > For example, say we have this merge target:
> >
> >  branch/            (depth == immediates)
> >  branch/notes/      (depth == empty)
> >  branch/src/        (depth == infinity)
> >  branch/README.TXT  (depth N/A)
> >
> > If we merge with no depth option specified the merge will not merge
> > any applicable changes into branch/src/*.
> >
> > Several people find this a bit counter-intuitive, and I agree:
> >
> > http://svn.haxx.se/dev/archive-2009-03/0701.shtml
> >
> > This can be worked around by passing --depth=infinity to the merge
> > subcommand, but I doubt many users will realize this.
> >
> > Also, this is inconsistent with how update works.  In the above
> > example if we update branch with no --depth or --set-depth option then
> > branch/src/* would get any available updates.
> >
> > I'd like to change merge's default depth to infinity.  Any objections
> > or thoughts?
> 
> +1

+1. Please, make it explicit if you don't want to use a recursive merge.

	Bert

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1630107

Re: RFC: Make default depth of merge infinity

Posted by Mark Phippard <ma...@gmail.com>.
On Thu, Apr 9, 2009 at 10:40 AM, Paul Burba <pt...@gmail.com> wrote:
> Currently (trunk@37129) the default depth of a merge is the depth of
> the merge target.  If the target has children that are at a deeper
> depth then those children are not merged to.
>
> For example, say we have this merge target:
>
>  branch/            (depth == immediates)
>  branch/notes/      (depth == empty)
>  branch/src/        (depth == infinity)
>  branch/README.TXT  (depth N/A)
>
> If we merge with no depth option specified the merge will not merge
> any applicable changes into branch/src/*.
>
> Several people find this a bit counter-intuitive, and I agree:
>
> http://svn.haxx.se/dev/archive-2009-03/0701.shtml
>
> This can be worked around by passing --depth=infinity to the merge
> subcommand, but I doubt many users will realize this.
>
> Also, this is inconsistent with how update works.  In the above
> example if we update branch with no --depth or --set-depth option then
> branch/src/* would get any available updates.
>
> I'd like to change merge's default depth to infinity.  Any objections
> or thoughts?

+1

Not to hijack this, but there are other depth problems lurking.  For
example, using your above example, this command:

svn update --set-depth=infinity branches

Does not change the depth of any of the children of branches to
infinity.  I cannot imagine anyone thinks that is the right behavior.


-- 
Thanks

Mark Phippard
http://markphip.blogspot.com/

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1620064