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

subtrees that don't exist at the start or end of a merge range shouldn't break the merge

    XMLWordPrintableJSON

Details

    Description

      When performing a repeat merge on a path which has a subtree which needs the
      merge (i.e. it isn't a repeat merge for the subtree) the merge
      
      For example, say we have this working copy:
      
      >svn log -r1:HEAD -v merge_tests-77
      ------------------------------------------------------------------------
      r1 | jrandom | 2008-01-08 11:21:12 -0500 (Tue, 08 Jan 2008) | 1 line
      Changed paths:
         A /A
         A /A/B
         A /A/B/E
         A /A/B/E/alpha
         A /A/B/E/beta
         A /A/B/F
         A /A/B/lambda
         A /A/C
         A /A/D
         A /A/D/G
         A /A/D/G/pi
         A /A/D/G/rho
         A /A/D/G/tau
         A /A/D/H
         A /A/D/H/chi
         A /A/D/H/omega
         A /A/D/H/psi
         A /A/D/gamma
         A /A/mu
         A /iota
      
      Log message for revision 1.
      ------------------------------------------------------------------------
      r2 | jrandom | 2008-01-08 11:21:23 -0500 (Tue, 08 Jan 2008) | 1 line
      Changed paths:
         A /A_COPY (from /A:1)
      
      log msg
      ------------------------------------------------------------------------
      r3 | jrandom | 2008-01-08 11:21:23 -0500 (Tue, 08 Jan 2008) | 1 line
      Changed paths:
         M /A/D/H/psi
      
      log msg
      ------------------------------------------------------------------------
      r4 | jrandom | 2008-01-08 11:21:24 -0500 (Tue, 08 Jan 2008) | 1 line
      Changed paths:
         M /A/D/G/rho
      
      log msg
      ------------------------------------------------------------------------
      r5 | jrandom | 2008-01-08 11:21:25 -0500 (Tue, 08 Jan 2008) | 1 line
      Changed paths:
         M /A/B/E/beta
      
      log msg
      ------------------------------------------------------------------------
      r6 | jrandom | 2008-01-08 11:21:26 -0500 (Tue, 08 Jan 2008) | 1 line
      Changed paths:
         M /A/D/H/omega
      
      log msg
      ------------------------------------------------------------------------
      r7 | jrandom | 2008-01-08 11:21:27 -0500 (Tue, 08 Jan 2008) | 1 line
      Changed paths:
         A /A/D/H/nu
      
      log msg
      ------------------------------------------------------------------------
      r8 | jrandom | 2008-01-08 11:21:28 -0500 (Tue, 08 Jan 2008) | 1 line
      Changed paths:
         M /A/D/H/nu
      
      log msg
      ------------------------------------------------------------------------
      
      >svn st merge_tests-77
       M     merge_tests-77\A_COPY
      M      merge_tests-77\A_COPY\B\E\beta
       M     merge_tests-77\A_COPY\D
       M     merge_tests-77\A_COPY\D\H
      A  +   merge_tests-77\A_COPY\D\H\nu
      
      >svn pl -vR merge_tests-77
      Properties on 'merge_tests-77\A_COPY':
        svn:mergeinfo : /A:5-6
      Properties on 'merge_tests-77\A_COPY\D':
        svn:mergeinfo : /A/D:5
      Properties on 'merge_tests-77\A_COPY\D\H':
        svn:mergeinfo : /A/D/H:5,7
      Properties on 'merge_tests-77\A_COPY\D\H\nu':
        svn:mergeinfo : /A/D/H/nu:5,7-8
      
      Now we try to repeat merge r6 to A_COPY.  A_COPY already has r6 in its
      mergeinfo, but it has several subtrees, A_COPY/D, A_COPY_D_H, and A_COPY/D/H/nu
      which do need r6 applied.  Problem is, A_COPY/D/H/nu was added in r7, and in
      this situation trunk currently calls reporter->set_path() in
      merge.c:drive_merge_report_editor() on '/D/H/nu' at revision 5, which leads to
      this error:
      
      >svn merge %url77%/A merge_tests-77\A_COPY -c6
      ..\..\..\subversion\libsvn_repos\reporter.c:778: (apr_err=160013)
      svn: Working copy path 'D/H/nu' does not exist in repository
      
      Interestingly enough this merge works if we change the target to A_COPY/D!
      >svn merge %url77%/A/D merge_tests-77\A_COPY\D -c6
      --- Merging r6 into 'merge_tests-77\A_COPY\D\H':
      U    merge_tests-77\A_COPY\D\H\omega
      
      C:\SVN\src-branch\Release\subversion\tests\cmdline\svn-test-work\working_copies>
      
      Haven't worked out yet the best fix for this, I'd definitely perplexed by the
      fact that the merge to A_COPY/D works fine.  Will commit a test on trunk for
      this momentarily.
      

      Attachments

        1. 6_3067.patch.v17
          22 kB
          Subversion Importer
        2. 5_3067.patch.v12
          19 kB
          Subversion Importer
        3. 4_3067.patch.v11
          15 kB
          Subversion Importer
        4. 3_3067.patch.v10
          15 kB
          Subversion Importer
        5. 2_3067.18.diff
          18 kB
          Paul Burba
        6. 1_3067.11.diff
          15 kB
          Paul Burba

        Activity

          People

            Unassigned Unassigned
            pburba Paul Burba
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: