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 <pb...@collab.net> on 2007/04/04 11:57:55 UTC

[PATCH]: Stop mer'G'e notification for files with local mods that are unchanged by merge

When merging into a file with preexisting local modifications, our code
in merge.c:merge_file_changed() always reports a mer'G'e has occurred,
even if the merge made no change to the file (i.e. svn_wc_merge2()
returns a merge outcome of svn_wc_merge_unchanged).

This results in a lot of incorrect notifications with merge-tracking -
see http://svn.haxx.se/dev/archive-2007-03/1157.shtml  But I'd argue
it's incorrect regardless of merge-tracking and would like to apply the
attached patch.  I see no problems with this, but Philip Martin's
question in merge_file_changed()...

      /* Philip asks "Why?"  Why does the notification depend on whether
the
         file had modifications before the merge?  If the merge didn't
change
         the file because the local mods already included the change why
does
         that result it "merged" notification?  That's information
available
         through the status command, while the fact that the merge
didn't
         change the file is lost :-( */

      if (content_state)
        {
          if (merge_outcome == svn_wc_merge_conflict)
            *content_state = svn_wc_notify_state_conflicted;
          else if (has_local_mods)
            *content_state = svn_wc_notify_state_merged;
          else if (merge_outcome == svn_wc_merge_merged)
            *content_state = svn_wc_notify_state_changed;
          else if (merge_outcome == svn_wc_merge_no_merge)
            *content_state = svn_wc_notify_state_missing;
          else /* merge_outcome == svn_wc_merge_unchanged */
            *content_state = svn_wc_notify_state_unchanged;

...has been there a long time and *something* gave him pause or I
suspect he would have fixed this way back in the day... 

Anyone know the history of this and/or have any objections?

Thanks,

Paul B.

[[[
Stop mer'G'e notifications for locally modified files unchanged by a
merge. 

* subversion/libsvn_client/merge.c
  (merge_file_changed): Make merge notifications for a given file
dependent on
  the outcome of the merge, not the local modification status of the
file prior
  to the merge.  Remove philip's longstanding puzzlement comment.

* subversion/tests/cmdline/merge_tests.py
  (textual_merges_galore,
  obey_reporter_api_semantics_while_doing_subtree_merges): Remove merge
  notifications no longer expected.
]]]

Notifcations for locally modified paths which aren't changed after a 'merge'

Posted by Daniel Rall <dl...@collab.net>.
On Thu, 05 Apr 2007, Michael Brouwer wrote:

> On 4/5/07, Paul Burba <pb...@collab.net> wrote:
> >
> >> -----Original Message-----
> >> From: Michael Brouwer [mailto:mb.7766@gmail.com]
> >> Sent: Wednesday, April 04, 2007 11:19 AM
> >> To: Kamesh Jayachandran
> >> Cc: Paul Burba; Mark Phippard; Subversion Development; Daniel
> >> Rall; Peter N. Lundblad; philip@codematters.co.uk
> >> Subject: Re: [PATCH]: Stop mer'G'e notification for files
> >> with local mods that are unchanged by merge
> >>
> >> Rather than outright hiding that the file changed why not
> >> implement what svk does, and show a lower case 'g' for files
> >> that had local changes, but where unmodified by the merge
> >> since they already contained the changes being merged into them?
...
> >Assuming that 'g' (or more likely some other capital letter code) were
> >used, what you suggest is certainly doable, but do people actually find
> >that information useful at all?  What would one typically do with this
> >information?
> >
> >I favor less, but more meaningful output from merge: conflicts and
> >'real' merges.  I put 'g' in the same class as changes to svn:mergeinfo,
> >reporting these would just add information of questionable* value.
> >
> >*Of course take all this with the requisite grain of salt, the merges I
> >do are infrequent and relatively simple, so there may be some real value
> >in 'g' that my world doesn't typically require...
>
> A 'g' merge as opposed to a 'G' merge mean the file wasn't changed.  This
> provides useful information.  This usually happens if you merge something
> that had already been merged before (due to merge tracking not being used or
> the merge tracking metadata being out of date, or someone using diff+patch
> to bring a change forward).  An alternative would be to display nothing,
> which since the file didn't change might work, but you'd not be telling the
> user about the conflict free duplicate merge.

Michael, in what way is a notifcations for a locally modified path
which isn't changed after a 'merge' useful to you?  Yes, it's
certainly more information; but I'd like to understand your use case
more thoroughly.

Thanks, Dan

Re: [PATCH]: Stop mer'G'e notification for files with local mods that are unchanged by merge

Posted by Michael Brouwer <mb...@gmail.com>.
A 'g' merge as opposed to a 'G' merge mean the file wasn't changed.  This
provides useful information.  This usually happens if you merge something
that had already been merged before (due to merge tracking not being used or
the merge tracking metadata being out of date, or someone using diff+patch
to bring a change forward).  An alternative would be to display nothing,
which since the file didn't change might work, but you'd not be telling the
user about the conflict free duplicate merge.

Michael


On 4/5/07, Paul Burba <pb...@collab.net> wrote:
>
> > -----Original Message-----
> > From: Michael Brouwer [mailto:mb.7766@gmail.com]
> > Sent: Wednesday, April 04, 2007 11:19 AM
> > To: Kamesh Jayachandran
> > Cc: Paul Burba; Mark Phippard; Subversion Development; Daniel
> > Rall; Peter N. Lundblad; philip@codematters.co.uk
> > Subject: Re: [PATCH]: Stop mer'G'e notification for files
> > with local mods that are unchanged by merge
> >
> > Rather than outright hiding that the file changed why not
> > implement what svk does, and show a lower case 'g' for files
> > that had local changes, but where unmodified by the merge
> > since they already contained the changes being merged into them?
>
> Hi Michael,
>
> Assuming that 'g' (or more likely some other capital letter code) were
> used, what you suggest is certainly doable, but do people actually find
> that information useful at all?  What would one typically do with this
> information?
>
> I favor less, but more meaningful output from merge: conflicts and
> 'real' merges.  I put 'g' in the same class as changes to svn:mergeinfo,
> reporting these would just add information of questionable* value.
>
> *Of course take all this with the requisite grain of salt, the merges I
> do are infrequent and relatively simple, so there may be some real value
> in 'g' that my world doesn't typically require...
>
> Paul B.
>

RE: [PATCH]: Stop mer'G'e notification for files with local mods that are unchanged by merge

Posted by Paul Burba <pb...@collab.net>.
> -----Original Message-----
> From: Michael Brouwer [mailto:mb.7766@gmail.com] 
> Sent: Wednesday, April 04, 2007 11:19 AM
> To: Kamesh Jayachandran
> Cc: Paul Burba; Mark Phippard; Subversion Development; Daniel 
> Rall; Peter N. Lundblad; philip@codematters.co.uk
> Subject: Re: [PATCH]: Stop mer'G'e notification for files 
> with local mods that are unchanged by merge
> 
> Rather than outright hiding that the file changed why not 
> implement what svk does, and show a lower case 'g' for files 
> that had local changes, but where unmodified by the merge 
> since they already contained the changes being merged into them? 

Hi Michael,

Assuming that 'g' (or more likely some other capital letter code) were
used, what you suggest is certainly doable, but do people actually find
that information useful at all?  What would one typically do with this
information?

I favor less, but more meaningful output from merge: conflicts and
'real' merges.  I put 'g' in the same class as changes to svn:mergeinfo,
reporting these would just add information of questionable* value.

*Of course take all this with the requisite grain of salt, the merges I
do are infrequent and relatively simple, so there may be some real value
in 'g' that my world doesn't typically require...

Paul B.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org


Re: [PATCH]: Stop mer'G'e notification for files with local mods that are unchanged by merge

Posted by Michael Brouwer <mb...@gmail.com>.
Rather than outright hiding that the file changed why not implement what svk
does, and show a lower case 'g' for files that had local changes, but where
unmodified by the merge since they already contained the changes being
merged into them?

Michael


On 4/4/07, Kamesh Jayachandran <ka...@collab.net> wrote:
>
> Paul Burba wrote:
> >> -----Original Message-----
> >> From: Kamesh Jayachandran
> >> Sent: Wednesday, April 04, 2007 8:29 AM
> >> To: Mark Phippard
> >> Cc: Paul Burba; Subversion Development; Daniel Rall; Peter N.
> >> Lundblad; philip@codematters.co.uk
> >> Subject: Re: [PATCH]: Stop mer'G'e notification for files
> >> with local mods that are unchanged by merge
> >>
> >> Mark Phippard wrote:
> >>
> >>> On 4/4/07, *Paul Burba* <pburba@collab.net
> >>>
> >> <ma...@collab.net>>
> >>
> >>> wrote:
> >>>
> >>>     When merging into a file with preexisting local
> >>>
> >> modifications, our
> >>
> >>>     code
> >>>     in merge.c:merge_file_changed() always reports a
> >>>
> >> mer'G'e has occurred,
> >>
> >>>     even if the merge made no change to the file (i.e.
> >>>
> >> svn_wc_merge2()
> >>
> >>>     returns a merge outcome of svn_wc_merge_unchanged).
> >>>
> >>>     This results in a lot of incorrect notifications with
> >>>
> >> merge-tracking -
> >>
> >>>     see http://svn.haxx.se/dev/archive-2007-03/1157.shtml
> >>>     <http://svn.haxx.se/dev/archive-2007-03/1157.shtml>
> >>>
> >> But I'd argue
> >>
> >>>     it's incorrect regardless of merge-tracking and would like to
> >>>     apply the
> >>>     attached patch.  I see no problems with this, but
> >>>
> >> Philip Martin's
> >>
> >>>     question in merge_file_changed()...
> >>>
> >>>
> >>> In your example (in the mailing list archive link), the file is not
> >>> updated by the merge, but the file's properties are.
> >>>
> >> Shouldn't there
> >>
> >>> be a notification due to the properties being updated?  Or are we
> >>> trying to suppress those when it is the mergeinfo property?
> >>>
> >>> With the possible exception that we are trying to hide the
> >>>
> >> updates to
> >>
> >>> mergeinfo properties, I'd have excpected to see a property update
> >>> notification.
> >>>
> >> For property merge we still get 'G' even if the WC already as
> >> the same local change.
> >>
> >
> > I might be misunderstanding Mark, but I think he is referring only to
> > svn:mergeinfo?
> >
> > If so this is somewhat of a separate issue.  Currently we do treat the
> > svn:mergeinfo prop as special and don't notify regarding changes to it
> > (hmmm, not sure if this always true but I think it is ATM).  I'm not
> > sure if this was by design, I see nothing in the specs that indicates it
> > was, perhaps Dan or Kamesh can speak to this?  Regardless I think the
> > current behavior is correct, svn:mergeinfo changes show up in status
> > (they are after all properties), but I wouldn't want to see them in the
> > output of svn merge since I see them more as meta-(meta?)-data on the
> > merge rather than part of it.
> >
>
> Yes since r19954(erstwhile merge-tracking branch) this suppression seems
> to be in place. Though I could not see the log message stating the same.
>
> With regards
> Kamesh Jayachandran
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: dev-help@subversion.tigris.org
>
>

Re: Property change notifications for "svn:mergeinfo"

Posted by Daniel Rall <dl...@collab.net>.
On Fri, 06 Apr 2007, Paul Burba wrote:

> I'll try to address both Dan and Mike's comments below
> 
> > -----Original Message-----
> > From: Daniel Rall [mailto:dlr@collab.net] 
> > Sent: Thursday, April 05, 2007 8:07 PM
> > 
> > Handling of the "svn:mergeinfo" property was hacked into
> > svn_wc__merge_props() in all the places that previously 
> > resulted in property conflicts, adding intelligent merging of 
> > the merge info itself.  However, we aren't currently setting 
> > the property state output variable to the appropriate value 
> > for each merge.
> > 
> > Should we announce property changes to the "svn:mergeinfo" property?
> > I think so.
> 
> > -----Original Message-----
> > From: C. Michael Pilato [mailto:cmpilato@collab.net] 
> > Sent: Friday, April 06, 2007 1:58 AM
> >
> > If, in fact, merge tracking information is merely 
> > "application specific book keeping data", then I think the 
> > choice to use Subversion properties to hold it was not such a 
> > good one.
> > 
> > Fortunately, it's *not* just stuff users should never see.  
> > It was designed to be human-hackable:  merge-tracking.txt 
> > lists as a goal the ability "to edit merge information in a 
> > human editable form."
> > 
> > Now, that's not to say folks won't want some way to 
> > optionally silence the mergeinfo diff spew from 'svn diff' -- 
> > but I think that should be optional behavior.  And I don't 
> > see any reason to hide the fact that the 'svn:mergeinfo' 
> > property has changed in 'svn status', 'svn update', etc.
> 
> A little clarification: svn status, update, switch, diff, etc. *do*
> treat svn:mergeinfo just like any other property.  Nothing being hidden,
> suppressed, or otherwise skipped there that I know nor was I proposing
> that we should do that.
> 
> My original observation of the current trunk behavior had only to do
> with 'svn merge' and its notification of svn:mergeinfo changes.  Take
> this simple example starting with (you know what's coming...) the
> standard greek test tree (...I love the greek tree!):
> 
> # Make a branch with
> # a URL --> WC copy
> --------------------
> >svn copy %URL%/A A_COPY
> A    A_COPY\B
> A    A_COPY\B\lambda
> A    A_COPY\B\E
> A    A_COPY\B\E\alpha
> A    A_COPY\B\E\beta
> A    A_COPY\B\F
> A    A_COPY\mu
> A    A_COPY\C
> A    A_COPY\D
> A    A_COPY\D\gamma
> A    A_COPY\D\G
> A    A_COPY\D\G\pi
> A    A_COPY\D\G\rho
> A    A_COPY\D\G\tau
> A    A_COPY\D\H
> A    A_COPY\D\H\chi
> A    A_COPY\D\H\omega
> A    A_COPY\D\H\psi
> Checked out revision 1.
> A         A_COPY
> 
> # The copy results in some
> # mergeinfo on the branch
> --------------------------------
> >svn pl -vR
> Properties on 'A_COPY':
>   svn:mergeinfo : /A:1
> 
> # Make a change in the branch
> # source and commit it and the
> # branch itself as r2
> -----------------------------
> >echo new content > A\B\E\alpha
> 
> >svn ci -m ""
> Sending        A\B\E\alpha
> Adding         A_COPY
> Transmitting file data .
> Committed revision 2.
> 
> # Now merge r2 into the branch
> ------------------------------
> >svn merge %URL%/A/B A_COPY\B -c2
> U    A_COPY\B\E\alpha
> 
> OK, finally, here is the crux of why svn:mergeinfo seems different to
> me:
> 
>   %URL%/A/B has no svn:mergeinfo property
> 
>   and
> 
>   A_COPY\B has no svn:mergeinfo property
> 
> So why would we expect to see 'UU   A_COPY\B\E\alpha' as the merge
> result?
> 
> Of course after the merge A_COPY\B "magically" has svn:mergeinfo:
> 
> >svn pl -vR
> Properties on 'A_COPY':
>   svn:mergeinfo : /A:1
> Properties on 'A_COPY\B':
>   svn:mergeinfo : /A/B:1-2
> 
> So maybe the merge should look like this instead?
> >svn merge %URL%/A/B A_COPY\B -c2
> UU   A_COPY\B\E\alpha
>  ^
> But doesn't that imply some property existed on the URL and/or WC before
> the merge?  Of course if we merged into 'A_COPY' that would be true and
> my argument for svn:mergeinfo specialness kinda goes out the window a
> bit :-\ 
> 
> FWIW, the fact that the mergeinfo has been added is still clear when we
> run svn status or diff:
...

When we apply our merge info-specific property merging logic to
property merges of the "svn:mergeinfo" property, we were failing to
send any property notifications.  I added reporting of these
notifications in r24738.

I think we should have a unit test here as well.

RE: Property change notifications for "svn:mergeinfo"

Posted by Paul Burba <pb...@collab.net>.
I'll try to address both Dan and Mike's comments below

> -----Original Message-----
> From: Daniel Rall [mailto:dlr@collab.net] 
> Sent: Thursday, April 05, 2007 8:07 PM
> 
> Handling of the "svn:mergeinfo" property was hacked into
> svn_wc__merge_props() in all the places that previously 
> resulted in property conflicts, adding intelligent merging of 
> the merge info itself.  However, we aren't currently setting 
> the property state output variable to the appropriate value 
> for each merge.
> 
> Should we announce property changes to the "svn:mergeinfo" property?
> I think so.

> -----Original Message-----
> From: C. Michael Pilato [mailto:cmpilato@collab.net] 
> Sent: Friday, April 06, 2007 1:58 AM
>
> If, in fact, merge tracking information is merely 
> "application specific book keeping data", then I think the 
> choice to use Subversion properties to hold it was not such a 
> good one.
> 
> Fortunately, it's *not* just stuff users should never see.  
> It was designed to be human-hackable:  merge-tracking.txt 
> lists as a goal the ability "to edit merge information in a 
> human editable form."
> 
> Now, that's not to say folks won't want some way to 
> optionally silence the mergeinfo diff spew from 'svn diff' -- 
> but I think that should be optional behavior.  And I don't 
> see any reason to hide the fact that the 'svn:mergeinfo' 
> property has changed in 'svn status', 'svn update', etc.

A little clarification: svn status, update, switch, diff, etc. *do*
treat svn:mergeinfo just like any other property.  Nothing being hidden,
suppressed, or otherwise skipped there that I know nor was I proposing
that we should do that.

My original observation of the current trunk behavior had only to do
with 'svn merge' and its notification of svn:mergeinfo changes.  Take
this simple example starting with (you know what's coming...) the
standard greek test tree (...I love the greek tree!):

# Make a branch with
# a URL --> WC copy
--------------------
>svn copy %URL%/A A_COPY
A    A_COPY\B
A    A_COPY\B\lambda
A    A_COPY\B\E
A    A_COPY\B\E\alpha
A    A_COPY\B\E\beta
A    A_COPY\B\F
A    A_COPY\mu
A    A_COPY\C
A    A_COPY\D
A    A_COPY\D\gamma
A    A_COPY\D\G
A    A_COPY\D\G\pi
A    A_COPY\D\G\rho
A    A_COPY\D\G\tau
A    A_COPY\D\H
A    A_COPY\D\H\chi
A    A_COPY\D\H\omega
A    A_COPY\D\H\psi
Checked out revision 1.
A         A_COPY

# The copy results in some
# mergeinfo on the branch
--------------------------------
>svn pl -vR
Properties on 'A_COPY':
  svn:mergeinfo : /A:1

# Make a change in the branch
# source and commit it and the
# branch itself as r2
-----------------------------
>echo new content > A\B\E\alpha

>svn ci -m ""
Sending        A\B\E\alpha
Adding         A_COPY
Transmitting file data .
Committed revision 2.

# Now merge r2 into the branch
------------------------------
>svn merge %URL%/A/B A_COPY\B -c2
U    A_COPY\B\E\alpha

OK, finally, here is the crux of why svn:mergeinfo seems different to
me:

  %URL%/A/B has no svn:mergeinfo property

  and

  A_COPY\B has no svn:mergeinfo property

So why would we expect to see 'UU   A_COPY\B\E\alpha' as the merge
result?

Of course after the merge A_COPY\B "magically" has svn:mergeinfo:

>svn pl -vR
Properties on 'A_COPY':
  svn:mergeinfo : /A:1
Properties on 'A_COPY\B':
  svn:mergeinfo : /A/B:1-2

So maybe the merge should look like this instead?
>svn merge %URL%/A/B A_COPY\B -c2
UU   A_COPY\B\E\alpha
 ^
But doesn't that imply some property existed on the URL and/or WC before
the merge?  Of course if we merged into 'A_COPY' that would be true and
my argument for svn:mergeinfo specialness kinda goes out the window a
bit :-\ 

FWIW, the fact that the mergeinfo has been added is still clear when we
run svn status or diff:

>svn st -uv
                1        1 jrandom      A\B\E\beta
                2        2 pburba       A\B\E\alpha
                1        1 jrandom      A\B\E
                1        1 jrandom      A\B\lambda
                1        1 jrandom      A\B\F
                1        1 jrandom      A\B
                1        1 jrandom      A\mu
                1        1 jrandom      A\C
                1        1 jrandom      A\D\gamma
                1        1 jrandom      A\D\G
                1        1 jrandom      A\D\G\pi
                1        1 jrandom      A\D\G\rho
                1        1 jrandom      A\D\G\tau
                1        1 jrandom      A\D\H
                1        1 jrandom      A\D\H\chi
                1        1 jrandom      A\D\H\omega
                1        1 jrandom      A\D\H\psi
                1        1 jrandom      A\D
                1        1 jrandom      A
 M              2        2 pburba       A_COPY\B
                2        2 pburba       A_COPY\B\lambda
                2        2 pburba       A_COPY\B\E
M               2        2 pburba       A_COPY\B\E\alpha
                2        2 pburba       A_COPY\B\E\beta
                2        2 pburba       A_COPY\B\F
                2        2 pburba       A_COPY\mu
                2        2 pburba       A_COPY\C
                2        2 pburba       A_COPY\D
                2        2 pburba       A_COPY\D\gamma
                2        2 pburba       A_COPY\D\G
                2        2 pburba       A_COPY\D\G\pi
                2        2 pburba       A_COPY\D\G\rho
                2        2 pburba       A_COPY\D\G\tau
                2        2 pburba       A_COPY\D\H
                2        2 pburba       A_COPY\D\H\chi
                2        2 pburba       A_COPY\D\H\omega
                2        2 pburba       A_COPY\D\H\psi
                2        2 pburba       A_COPY
                1        1 jrandom      iota
                1        1 jrandom      .
Status against revision:      2

>svn diff

Property changes on: A_COPY\B
___________________________________________________________________
Name: svn:mergeinfo
   Merged /A/B:r1-2

Index: A_COPY/B/E/alpha
===================================================================
--- A_COPY/B/E/alpha    (revision 2)
+++ A_COPY/B/E/alpha    (working copy)
@@ -1 +1 @@
-This is the file 'alpha'.
+new content

Anyway, I don't actually feel that strongly about all this, but just
want to explain myself a bit.

Paul B.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org


Re: Property change notifications for "svn:mergeinfo"

Posted by "C. Michael Pilato" <cm...@collab.net>.
Kamesh Jayachandran wrote:
> 
>>Should we announce property changes to the "svn:mergeinfo" property?
>>I think so.
> 
> As mentioned by Paul, It won't make sense to announce 'svn:mergeinfo'
> prop changes as it is a application specific book keeping data would
> make no sense to end user.

If, in fact, merge tracking information is merely "application specific book
keeping data", then I think the choice to use Subversion properties to hold
it was not such a good one.

Fortunately, it's *not* just stuff users should never see.  It was designed
to be human-hackable:  merge-tracking.txt lists as a goal the ability "to
edit merge information in a human editable form."

Now, that's not to say folks won't want some way to optionally silence the
mergeinfo diff spew from 'svn diff' -- but I think that should be optional
behavior.  And I don't see any reason to hide the fact that the
'svn:mergeinfo' property has changed in 'svn status', 'svn update', etc.

-- 
C. Michael Pilato <cm...@collab.net>
CollabNet   <>   www.collab.net   <>   Distributed Development On Demand


RE: Property change notifications for "svn:mergeinfo"

Posted by Kamesh Jayachandran <ka...@collab.net>.
>Should we announce property changes to the "svn:mergeinfo" property?
>I think so.

As mentioned by Paul, It won't make sense to announce 'svn:mergeinfo' prop changes as it is a application specific book keeping data would make no sense to end user.

With regards
Kamesh Jayachandran

Property change notifications for "svn:mergeinfo"

Posted by Daniel Rall <dl...@collab.net>.
On Wed, 04 Apr 2007, Kamesh Jayachandran wrote:

> Paul Burba wrote:
...
> >If so this is somewhat of a separate issue.  Currently we do treat the
> >svn:mergeinfo prop as special and don't notify regarding changes to it
> >(hmmm, not sure if this always true but I think it is ATM).  I'm not
> >sure if this was by design, I see nothing in the specs that indicates it
> >was, perhaps Dan or Kamesh can speak to this?  Regardless I think the
> >current behavior is correct, svn:mergeinfo changes show up in status
> >(they are after all properties), but I wouldn't want to see them in the
> >output of svn merge since I see them more as meta-(meta?)-data on the
> >merge rather than part of it.
>
> Yes since r19954(erstwhile merge-tracking branch) this suppression seems 
> to be in place. Though I could not see the log message stating the same.

This was an unintended side-effect of r19954.  The deal with property
"merging" is that we don't actually do it using a diff or diff3
algorithm.  subversion/libsvn_wc:svn_wc__merge_props() is a big nasty
routine that handles all the possible permutations of "merging"
explicitly (most "merges" result in conflicts, as heavy users of
svnmerge.py are probably well aware from the joyful dir_conflicts.prej
files which are often the result of a merge).  I personally find this
somewhat strange, since we have sufficient information to use the
diff3 algorithm.  I'm assuming it's simply that no one has found the
time to implement this, given that a typical case probably involves
single-line property values where diff3 is of little assistance.

Handling of the "svn:mergeinfo" property was hacked into
svn_wc__merge_props() in all the places that previously resulted in
property conflicts, adding intelligent merging of the merge info
itself.  However, we aren't currently setting the property state
output variable to the appropriate value for each merge.

Should we announce property changes to the "svn:mergeinfo" property?
I think so.

Re: [PATCH]: Stop mer'G'e notification for files with local mods that are unchanged by merge

Posted by Kamesh Jayachandran <ka...@collab.net>.
Paul Burba wrote:
>> -----Original Message-----
>> From: Kamesh Jayachandran 
>> Sent: Wednesday, April 04, 2007 8:29 AM
>> To: Mark Phippard
>> Cc: Paul Burba; Subversion Development; Daniel Rall; Peter N. 
>> Lundblad; philip@codematters.co.uk
>> Subject: Re: [PATCH]: Stop mer'G'e notification for files 
>> with local mods that are unchanged by merge
>>
>> Mark Phippard wrote:
>>     
>>> On 4/4/07, *Paul Burba* <pburba@collab.net 
>>>       
>> <ma...@collab.net>>
>>     
>>> wrote:
>>>
>>>     When merging into a file with preexisting local 
>>>       
>> modifications, our
>>     
>>>     code
>>>     in merge.c:merge_file_changed() always reports a 
>>>       
>> mer'G'e has occurred,
>>     
>>>     even if the merge made no change to the file (i.e. 
>>>       
>> svn_wc_merge2()
>>     
>>>     returns a merge outcome of svn_wc_merge_unchanged).
>>>
>>>     This results in a lot of incorrect notifications with 
>>>       
>> merge-tracking -
>>     
>>>     see http://svn.haxx.se/dev/archive-2007-03/1157.shtml
>>>     <http://svn.haxx.se/dev/archive-2007-03/1157.shtml>  
>>>       
>> But I'd argue
>>     
>>>     it's incorrect regardless of merge-tracking and would like to
>>>     apply the
>>>     attached patch.  I see no problems with this, but 
>>>       
>> Philip Martin's
>>     
>>>     question in merge_file_changed()...
>>>
>>>
>>> In your example (in the mailing list archive link), the file is not 
>>> updated by the merge, but the file's properties are.  
>>>       
>> Shouldn't there 
>>     
>>> be a notification due to the properties being updated?  Or are we 
>>> trying to suppress those when it is the mergeinfo property?
>>>
>>> With the possible exception that we are trying to hide the 
>>>       
>> updates to 
>>     
>>> mergeinfo properties, I'd have excpected to see a property update 
>>> notification.
>>>       
>> For property merge we still get 'G' even if the WC already as 
>> the same local change.
>>     
>
> I might be misunderstanding Mark, but I think he is referring only to
> svn:mergeinfo?
>
> If so this is somewhat of a separate issue.  Currently we do treat the
> svn:mergeinfo prop as special and don't notify regarding changes to it
> (hmmm, not sure if this always true but I think it is ATM).  I'm not
> sure if this was by design, I see nothing in the specs that indicates it
> was, perhaps Dan or Kamesh can speak to this?  Regardless I think the
> current behavior is correct, svn:mergeinfo changes show up in status
> (they are after all properties), but I wouldn't want to see them in the
> output of svn merge since I see them more as meta-(meta?)-data on the
> merge rather than part of it.
>   

Yes since r19954(erstwhile merge-tracking branch) this suppression seems 
to be in place. Though I could not see the log message stating the same.

With regards
Kamesh Jayachandran

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: [PATCH]: Stop mer'G'e notification for files with local modsthat are unchanged by merge

Posted by Mark Phippard <ma...@gmail.com>.
On 4/4/07, Bhuvaneswaran Arumugam <bh...@collab.net> wrote:
> Yes, it comes in HTML. If you use Gmail you, I think you are using "Rich
> Formatting" mode while composing the email. If you switch back to "Plain
> Text" mode, I think it should be fine.

Thanks.  I was looking for something in the settings.  I found it on
the editor as you suggested.

-- 
Thanks

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

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: [PATCH]: Stop mer'G'e notification for files with local modsthat are unchanged by merge

Posted by Bhuvaneswaran Arumugam <bh...@collab.net>.
On Wed, 2007-04-04 at 08:57 -0400, Mark Phippard wrote:
> On 4/4/07, Paul Burba <pb...@collab.net> wrote:
>         > -----Original Message-----
>         > From: Kamesh Jayachandran
>         > Sent: Wednesday, April 04, 2007 8:29 AM
>         > To: Mark Phippard
>         > Cc: Paul Burba; Subversion Development; Daniel Rall; Peter
>         N.
>         > Lundblad; philip@codematters.co.uk
>         > Subject: Re: [PATCH]: Stop mer'G'e notification for files
>         > with local mods that are unchanged by merge
>         >
>         > Mark Phippard wrote: 
>         > > On 4/4/07, *Paul Burba* <pburba@collab.net
>         > <ma...@collab.net>>
>         > > wrote:
>         > >
>         > >     When merging into a file with preexisting local 
>         > modifications, our
>         > >     code
>         > >     in merge.c:merge_file_changed() always reports a
>         > mer'G'e has occurred,
>         > >     even if the merge made no change to the file (i.e. 
>         > svn_wc_merge2()
>         > >     returns a merge outcome of svn_wc_merge_unchanged).
>         > >
>         > >     This results in a lot of incorrect notifications with
>         > merge-tracking -
>         > >     see http://svn.haxx.se/dev/archive-2007-03/1157.shtml
>         > >     <http://svn.haxx.se/dev/archive-2007-03/1157.shtml>
>         > But I'd argue
>         > >     it's incorrect regardless of merge-tracking and would
>         like to
>         > >     apply the
>         > >     attached patch.  I see no problems with this, but
>         > Philip Martin's 
>         > >     question in merge_file_changed()...
>         > >
>         > >
>         > > In your example (in the mailing list archive link), the
>         file is not
>         > > updated by the merge, but the file's properties are. 
>         > Shouldn't there
>         > > be a notification due to the properties being updated?  Or
>         are we
>         > > trying to suppress those when it is the mergeinfo
>         property?
>         > >
>         > > With the possible exception that we are trying to hide
>         the 
>         > updates to
>         > > mergeinfo properties, I'd have excpected to see a property
>         update
>         > > notification.
>         > For property merge we still get 'G' even if the WC already
>         as
>         > the same local change. 
>         
>         I might be misunderstanding Mark, but I think he is referring
>         only to
>         svn:mergeinfo?
>         
>         If so this is somewhat of a separate issue.  Currently we do
>         treat the
>         svn:mergeinfo prop as special and don't notify regarding
>         changes to it 
>         (hmmm, not sure if this always true but I think it is
>         ATM).  I'm not
>         sure if this was by design, I see nothing in the specs that
>         indicates it
>         was, perhaps Dan or Kamesh can speak to this?  Regardless I
>         think the 
>         current behavior is correct, svn:mergeinfo changes show up in
>         status
>         (they are after all properties), but I wouldn't want to see
>         them in the
>         output of svn merge since I see them more as meta-(meta?)-data
>         on the 
>         merge rather than part of it.
> 
> OK, so let's say another property was set and merge updated the
> property value, what would it report as?
> 
> What I was kind of getting at is maybe 'G' is expected here because of
> the property update and the real fix is to hide it when only mergeinfo
> is updated? 
> 
> Just guessing.
> 
> Paul told me he has trouble replying to my emails because they come to
> him in HTML.  I do not see any GMail settings to control this.  Does
> anyone else have problems with my emails?  I assumed GMail would
> handle this "right", but I suppose in this case what is right is a
> bikeshed. 

Yes, it comes in HTML. If you use Gmail you, I think you are using "Rich
Formatting" mode while composing the email. If you switch back to "Plain
Text" mode, I think it should be fine.

-- 
Regards,
Bhuvaneswaran

RE: [PATCH]: Stop mer'G'e notification for files with local mods that are unchanged by merge

Posted by Paul Burba <pb...@collab.net>.
> -----Original Message-----
> From: Mark Phippard [mailto:markphip@gmail.com] 
> Sent: Wednesday, April 04, 2007 8:57 AM
> To: Paul Burba
> Cc: Kamesh Jayachandran; Subversion Development; Daniel Rall; 
> Peter N. Lundblad; philip@codematters.co.uk
> Subject: Re: [PATCH]: Stop mer'G'e notification for files 
> with local mods that are unchanged by merge

<snip>

> 	I might be misunderstanding Mark, but I think he is 
> referring only to
> 	svn:mergeinfo?
> 	
> 	If so this is somewhat of a separate issue.  Currently 
> we do treat the
> 	svn:mergeinfo prop as special and don't notify 
> regarding changes to it 
> 	(hmmm, not sure if this always true but I think it is 
> ATM).  I'm not
> 	sure if this was by design, I see nothing in the specs 
> that indicates it
> 	was, perhaps Dan or Kamesh can speak to this?  
> Regardless I think the 
> 	current behavior is correct, svn:mergeinfo changes show 
> up in status
> 	(they are after all properties), but I wouldn't want to 
> see them in the
> 	output of svn merge since I see them more as 
> meta-(meta?)-data on the 
> 	merge rather than part of it.
> 
> 
> OK, so let's say another property was set and merge updated 
> the property value, what would it report as?

It would report as ' U' -- All prop changes (other than svn:mergeinfo)
are reported normally regardless of my patch.

> What I was kind of getting at is maybe 'G' is expected here 
> because of the property update and the real fix is to hide it 
> when only mergeinfo is updated? 

My fault for not clarifying at the start of this thread that I was
referring to local *text* modifications 'M ' not prop mods ' M' and text
merges 'G ' not prop merges ' G'.  Property and text change
notifications are handled separately within merge_file_changed() so that
is not the problem.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org


Re: [PATCH]: Stop mer'G'e notification for files with local mods that are unchanged by merge

Posted by Mark Phippard <ma...@gmail.com>.
On 4/4/07, Paul Burba <pb...@collab.net> wrote:
>
> > -----Original Message-----
> > From: Kamesh Jayachandran
> > Sent: Wednesday, April 04, 2007 8:29 AM
> > To: Mark Phippard
> > Cc: Paul Burba; Subversion Development; Daniel Rall; Peter N.
> > Lundblad; philip@codematters.co.uk
> > Subject: Re: [PATCH]: Stop mer'G'e notification for files
> > with local mods that are unchanged by merge
> >
> > Mark Phippard wrote:
> > > On 4/4/07, *Paul Burba* <pburba@collab.net
> > <ma...@collab.net>>
> > > wrote:
> > >
> > >     When merging into a file with preexisting local
> > modifications, our
> > >     code
> > >     in merge.c:merge_file_changed() always reports a
> > mer'G'e has occurred,
> > >     even if the merge made no change to the file (i.e.
> > svn_wc_merge2()
> > >     returns a merge outcome of svn_wc_merge_unchanged).
> > >
> > >     This results in a lot of incorrect notifications with
> > merge-tracking -
> > >     see http://svn.haxx.se/dev/archive-2007-03/1157.shtml
> > >     <http://svn.haxx.se/dev/archive-2007-03/1157.shtml>
> > But I'd argue
> > >     it's incorrect regardless of merge-tracking and would like to
> > >     apply the
> > >     attached patch.  I see no problems with this, but
> > Philip Martin's
> > >     question in merge_file_changed()...
> > >
> > >
> > > In your example (in the mailing list archive link), the file is not
> > > updated by the merge, but the file's properties are.
> > Shouldn't there
> > > be a notification due to the properties being updated?  Or are we
> > > trying to suppress those when it is the mergeinfo property?
> > >
> > > With the possible exception that we are trying to hide the
> > updates to
> > > mergeinfo properties, I'd have excpected to see a property update
> > > notification.
> > For property merge we still get 'G' even if the WC already as
> > the same local change.
>
> I might be misunderstanding Mark, but I think he is referring only to
> svn:mergeinfo?
>
> If so this is somewhat of a separate issue.  Currently we do treat the
> svn:mergeinfo prop as special and don't notify regarding changes to it
> (hmmm, not sure if this always true but I think it is ATM).  I'm not
> sure if this was by design, I see nothing in the specs that indicates it
> was, perhaps Dan or Kamesh can speak to this?  Regardless I think the
> current behavior is correct, svn:mergeinfo changes show up in status
> (they are after all properties), but I wouldn't want to see them in the
> output of svn merge since I see them more as meta-(meta?)-data on the
> merge rather than part of it.


OK, so let's say another property was set and merge updated the property
value, what would it report as?

What I was kind of getting at is maybe 'G' is expected here because of the
property update and the real fix is to hide it when only mergeinfo is
updated?

Just guessing.

Paul told me he has trouble replying to my emails because they come to him
in HTML.  I do not see any GMail settings to control this.  Does anyone else
have problems with my emails?  I assumed GMail would handle this "right",
but I suppose in this case what is right is a bikeshed.

-- 
Thanks

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

RE: [PATCH]: Stop mer'G'e notification for files with local mods that are unchanged by merge

Posted by Paul Burba <pb...@collab.net>.
> -----Original Message-----
> From: Kamesh Jayachandran 
> Sent: Wednesday, April 04, 2007 8:29 AM
> To: Mark Phippard
> Cc: Paul Burba; Subversion Development; Daniel Rall; Peter N. 
> Lundblad; philip@codematters.co.uk
> Subject: Re: [PATCH]: Stop mer'G'e notification for files 
> with local mods that are unchanged by merge
> 
> Mark Phippard wrote:
> > On 4/4/07, *Paul Burba* <pburba@collab.net 
> <ma...@collab.net>>
> > wrote:
> >
> >     When merging into a file with preexisting local 
> modifications, our
> >     code
> >     in merge.c:merge_file_changed() always reports a 
> mer'G'e has occurred,
> >     even if the merge made no change to the file (i.e. 
> svn_wc_merge2()
> >     returns a merge outcome of svn_wc_merge_unchanged).
> >
> >     This results in a lot of incorrect notifications with 
> merge-tracking -
> >     see http://svn.haxx.se/dev/archive-2007-03/1157.shtml
> >     <http://svn.haxx.se/dev/archive-2007-03/1157.shtml>  
> But I'd argue
> >     it's incorrect regardless of merge-tracking and would like to
> >     apply the
> >     attached patch.  I see no problems with this, but 
> Philip Martin's
> >     question in merge_file_changed()...
> >
> >
> > In your example (in the mailing list archive link), the file is not 
> > updated by the merge, but the file's properties are.  
> Shouldn't there 
> > be a notification due to the properties being updated?  Or are we 
> > trying to suppress those when it is the mergeinfo property?
> >
> > With the possible exception that we are trying to hide the 
> updates to 
> > mergeinfo properties, I'd have excpected to see a property update 
> > notification.
> For property merge we still get 'G' even if the WC already as 
> the same local change.

I might be misunderstanding Mark, but I think he is referring only to
svn:mergeinfo?

If so this is somewhat of a separate issue.  Currently we do treat the
svn:mergeinfo prop as special and don't notify regarding changes to it
(hmmm, not sure if this always true but I think it is ATM).  I'm not
sure if this was by design, I see nothing in the specs that indicates it
was, perhaps Dan or Kamesh can speak to this?  Regardless I think the
current behavior is correct, svn:mergeinfo changes show up in status
(they are after all properties), but I wouldn't want to see them in the
output of svn merge since I see them more as meta-(meta?)-data on the
merge rather than part of it.

Paul B. 
 
> With regards
> Kamesh Jayachandran

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org


Re: [PATCH]: Stop mer'G'e notification for files with local mods that are unchanged by merge

Posted by Kamesh Jayachandran <ka...@collab.net>.
Mark Phippard wrote:
> On 4/4/07, *Paul Burba* <pburba@collab.net <ma...@collab.net>> 
> wrote:
>
>     When merging into a file with preexisting local modifications, our
>     code
>     in merge.c:merge_file_changed() always reports a mer'G'e has occurred,
>     even if the merge made no change to the file (i.e. svn_wc_merge2()
>     returns a merge outcome of svn_wc_merge_unchanged).
>
>     This results in a lot of incorrect notifications with merge-tracking -
>     see http://svn.haxx.se/dev/archive-2007-03/1157.shtml
>     <http://svn.haxx.se/dev/archive-2007-03/1157.shtml>  But I'd argue
>     it's incorrect regardless of merge-tracking and would like to
>     apply the
>     attached patch.  I see no problems with this, but Philip Martin's
>     question in merge_file_changed()...
>
>
> In your example (in the mailing list archive link), the file is not 
> updated by the merge, but the file's properties are.  Shouldn't there 
> be a notification due to the properties being updated?  Or are we 
> trying to suppress those when it is the mergeinfo property?
>
> With the possible exception that we are trying to hide the updates to 
> mergeinfo properties, I'd have excpected to see a property update 
> notification.
For property merge we still get 'G' even if the WC already as the same 
local change.

With regards
Kamesh Jayachandran

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: [PATCH]: Stop mer'G'e notification for files with local mods that are unchanged by merge

Posted by Mark Phippard <ma...@gmail.com>.
On 4/4/07, Paul Burba <pb...@collab.net> wrote:
>
> When merging into a file with preexisting local modifications, our code
> in merge.c:merge_file_changed() always reports a mer'G'e has occurred,
> even if the merge made no change to the file (i.e. svn_wc_merge2()
> returns a merge outcome of svn_wc_merge_unchanged).
>
> This results in a lot of incorrect notifications with merge-tracking -
> see http://svn.haxx.se/dev/archive-2007-03/1157.shtml  But I'd argue
> it's incorrect regardless of merge-tracking and would like to apply the
> attached patch.  I see no problems with this, but Philip Martin's
> question in merge_file_changed()...


In your example (in the mailing list archive link), the file is not updated
by the merge, but the file's properties are.  Shouldn't there be a
notification due to the properties being updated?  Or are we trying to
suppress those when it is the mergeinfo property?

With the possible exception that we are trying to hide the updates to
mergeinfo properties, I'd have excpected to see a property update
notification.

-- 
Thanks

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

RE: [PATCH]: Stop mer'G'e notification for files with local mods that are unchanged by merge

Posted by Paul Burba <pb...@collab.net>.
> -----Original Message-----
> From: Daniel Rall [mailto:dlr@collab.net] 
> Sent: Thursday, April 05, 2007 7:16 PM
> To: Paul Burba
> Cc: Subversion Development; Kamesh Jayachandran; Karl Fogel; 
> philip@codematters.co.uk
> Subject: Re: [PATCH]: Stop mer'G'e notification for files 
> with local mods that are unchanged by merge
> 
> On Wed, 04 Apr 2007, Paul Burba wrote:
> 
> > When merging into a file with preexisting local modifications, our 
> > code in merge.c:merge_file_changed() always reports a mer'G'e has 
> > occurred, even if the merge made no change to the file (i.e. 
> > svn_wc_merge2() returns a merge outcome of svn_wc_merge_unchanged).
> > 
> > This results in a lot of incorrect notifications with 
> merge-tracking - 
> > see http://svn.haxx.se/dev/archive-2007-03/1157.shtml  But 
> I'd argue 
> > it's incorrect regardless of merge-tracking and would like to apply 
> > the attached patch.  I see no problems with this, but 
> Philip Martin's 
> > question in merge_file_changed()...
> > 
> >       /* Philip asks "Why?"  Why does the notification depend on 
> > whether the
> >          file had modifications before the merge?  If the 
> merge didn't 
> > change
> >          the file because the local mods already included 
> the change 
> > why does
> >          that result it "merged" notification?  That's information 
> > available
> >          through the status command, while the fact that the merge 
> > didn't
> >          change the file is lost :-( */
> > 
> >       if (content_state)
> >         {
> >           if (merge_outcome == svn_wc_merge_conflict)
> >             *content_state = svn_wc_notify_state_conflicted;
> >           else if (has_local_mods)
> >             *content_state = svn_wc_notify_state_merged;
> >           else if (merge_outcome == svn_wc_merge_merged)
> >             *content_state = svn_wc_notify_state_changed;
> >           else if (merge_outcome == svn_wc_merge_no_merge)
> >             *content_state = svn_wc_notify_state_missing;
> >           else /* merge_outcome == svn_wc_merge_unchanged */
> >             *content_state = svn_wc_notify_state_unchanged;
> > 
> > ...has been there a long time and *something* gave him pause or I 
> > suspect he would have fixed this way back in the day...
> > 
> > Anyone know the history of this and/or have any objections?
> 
> Paul, I don't have first-hand knowledge of the history behind 
> this code.  Looking back through libsvn_client/diff.c's VC 
> history, this code was introduced in r2305 to fix issue #662, 
> "making merge callbacks use the new notification system."  
> Philip added his comment
> 5 months later in r3640.  At face value, it doesn't look to 
> me like the code was ever correct.
>
> +1 on committing your patch, and nominating this bug fix for backport
> to the 1.4.x and 1.3.x branches.

Thanks for taking a look Dan.  Committed r24483 and nominated for
backport (I added you as a +1 for both - assuming it was implied).

Paul B.
 

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org


Re: [PATCH]: Stop mer'G'e notification for files with local mods that are unchanged by merge

Posted by Daniel Rall <dl...@collab.net>.
On Wed, 04 Apr 2007, Paul Burba wrote:

> When merging into a file with preexisting local modifications, our code
> in merge.c:merge_file_changed() always reports a mer'G'e has occurred,
> even if the merge made no change to the file (i.e. svn_wc_merge2()
> returns a merge outcome of svn_wc_merge_unchanged).
> 
> This results in a lot of incorrect notifications with merge-tracking -
> see http://svn.haxx.se/dev/archive-2007-03/1157.shtml  But I'd argue
> it's incorrect regardless of merge-tracking and would like to apply the
> attached patch.  I see no problems with this, but Philip Martin's
> question in merge_file_changed()...
> 
>       /* Philip asks "Why?"  Why does the notification depend on whether
> the
>          file had modifications before the merge?  If the merge didn't
> change
>          the file because the local mods already included the change why
> does
>          that result it "merged" notification?  That's information
> available
>          through the status command, while the fact that the merge
> didn't
>          change the file is lost :-( */
> 
>       if (content_state)
>         {
>           if (merge_outcome == svn_wc_merge_conflict)
>             *content_state = svn_wc_notify_state_conflicted;
>           else if (has_local_mods)
>             *content_state = svn_wc_notify_state_merged;
>           else if (merge_outcome == svn_wc_merge_merged)
>             *content_state = svn_wc_notify_state_changed;
>           else if (merge_outcome == svn_wc_merge_no_merge)
>             *content_state = svn_wc_notify_state_missing;
>           else /* merge_outcome == svn_wc_merge_unchanged */
>             *content_state = svn_wc_notify_state_unchanged;
> 
> ...has been there a long time and *something* gave him pause or I
> suspect he would have fixed this way back in the day... 
> 
> Anyone know the history of this and/or have any objections?

Paul, I don't have first-hand knowledge of the history behind this
code.  Looking back through libsvn_client/diff.c's VC history, this
code was introduced in r2305 to fix issue #662, "making merge
callbacks use the new notification system."  Philip added his comment
5 months later in r3640.  At face value, it doesn't look to me like
the code was ever correct.

+1 on committing your patch, and nominating this bug fix for backport
to the 1.4.x and 1.3.x branches.