Uploaded image for project: 'Subversion'
  1. Subversion
  2. SVN-3407

Shallow merges incorrectly set mergeinfo on children

    XMLWordPrintableJSON

    Details

      Description

      As described here,
      http://subversion.open.collab.net/ds/viewMessage.do?dsForumId=4&dsMessageId=313877,
      when a shallow merge target has non-inheritable mergeinfo, the merge sets
      mergeinfo on children of the target that should, per the requested depth, not be
      touched by the merge:
      
      # 1) svn merge --depth empty sets mergeinfo on all children:
      
      trunk.release>svn st -v A_COPY
                      13        9 jrandom      A_COPY
                      13        2 jrandom      A_COPY\mu
                      13        2 jrandom      A_COPY\B
                      13        2 jrandom      A_COPY\B\lambda
                      13        2 jrandom      A_COPY\B\E
                      13        2 jrandom      A_COPY\B\E\alpha
                      13        2 jrandom      A_COPY\B\E\beta
                      13        2 jrandom      A_COPY\B\F
                      13        2 jrandom      A_COPY\C
                      13        2 jrandom      A_COPY\D
                      13        2 jrandom      A_COPY\D\gamma
                      13        2 jrandom      A_COPY\D\G
                      13        2 jrandom      A_COPY\D\G\rho
                      13        2 jrandom      A_COPY\D\G\pi
                      13        2 jrandom      A_COPY\D\G\tau
                      13        2 jrandom      A_COPY\D\H
                      13        2 jrandom      A_COPY\D\H\chi
                      13        2 jrandom      A_COPY\D\H\omega
                      13        2 jrandom      A_COPY\D\H\psi
      
      # The merge target has non-inheritable mergeinfo:
      
      trunk.release>svn pl -vR A_COPY
      Properties on 'A_COPY':
        svn:mergeinfo
          /A:2-8*
      
      trunk.release>svn merge %url%/A A_COPY --depth empty
      
      # There shouldn't be mergeinfo added to *any* child of A_COPY!
      # The non-inheritable mergeinfo set on A_COPY is sufficient
      # to describe the merge.
      
      trunk.release>svn st
       M      A_COPY
       M      A_COPY\mu
       M      A_COPY\B
       M      A_COPY\C
       M      A_COPY\D
      
      trunk.release>svn pl -vR A_COPY
      Properties on 'A_COPY':
        svn:mergeinfo
          /A:2-13*
      Properties on 'A_COPY\mu':
        svn:mergeinfo
          /A/mu:2-13
      Properties on 'A_COPY\B':
        svn:mergeinfo
          /A/B:2-13*
      Properties on 'A_COPY\C':
        svn:mergeinfo
          /A/C:2-13*
      Properties on 'A_COPY\D':
        svn:mergeinfo
          /A/D:2-13*
      
      trunk.release>svn revert -R .
      Reverted 'A_COPY'
      Reverted 'A_COPY\mu'
      Reverted 'A_COPY\B'
      Reverted 'A_COPY\C'
      Reverted 'A_COPY\D'
      
      # 2) svn merge --depth files sets mergeinfo on all children:
      
      trunk.release>svn merge %url%/A A_COPY --depth files
      --- Merging r2 through r13 into 'A_COPY\mu':
      UU   A_COPY\mu
      --- Merging r9 through r13 into 'A_COPY':
      A    A_COPY\nu
      
      # There should not be mereginfo on the directory children of A_COPY.
      # The non-inheritable mergeinfo set on A_COPY and the normal
      # mergeinfo set on its file children is sufficient to describe
      # the merge.
      
      trunk.release>svn st
       M      A_COPY
      MM      A_COPY\mu
       M      A_COPY\B
      A  +    A_COPY\nu
       M      A_COPY\C
       M      A_COPY\D
      
      trunk.release>svn pl -vR A_COPY
      Properties on 'A_COPY':
        svn:mergeinfo
          /A:2-13*
      Properties on 'A_COPY\mu':
        svn:mergeinfo
          /A/mu:2-13
      Properties on 'A_COPY\B':
        svn:mergeinfo
          /A/B:2-13*
      Properties on 'A_COPY\nu':
        svn:mergeinfo
          /A/nu:2-13
      Properties on 'A_COPY\C':
        svn:mergeinfo
          /A/C:2-13*
      Properties on 'A_COPY\D':
        svn:mergeinfo
          /A/D:2-13*
      

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              pburba Paul Burba
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: