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

Problems when using externals while merging from trunk into a branch

From: Uwe Voellger <U.Voellger_at_intershop.de>
Date: Wed, 4 Nov 2009 09:58:26 +0100

General information:
====================
 
OS: Windows XP (SVN server and client)
Release: 1.6.6 downloaded from Collabnet
 

Description:
============
 
When merging all changes from trunk into a branch created from the
trunk, and if the trunk (and branch) contain several externals pointing
to the same target, svn:mergeinfo is attached to the wrong directories
resp. files.
 
In the scenario described by the test steps, I would expect the
following:
- Since no real changes happened, the only change we would expect is a
mergeinfo attached to the root of merge, which is in this case
\testrepository\branches\linktest. In case the external target is not
below this root, I would expect a second mergeinfo entry attached to the
link target, but in this case this was not true.
- I would not expect any change on source1 or source2 since they reside
below the merge root.
- Attaching mergeinfo to source1\linksource1.txt or
source2\linksource1.txt is an error: there is no such file. Only an
external exists, which should get the property change if it does not
reside below the merge root.
- An error also occurs when trying to commit the changes in one step
since both source1\linksource1.txt and source2\linksource1.txt point to
the same target.
 

Steps to reproduce:
===================
 
>cd /D D:\svn_wc\testreporsitory\trunk
 
>mkdir linktest
 
>mkdir linktest\source1
 
>mkdir linktest\source2
 
>mkdir linktest\target
 
>echo "hello" > linktest\target\linktarget1.txt
 
>echo "hello" > linktest\target\linktarget2.txt
 
>dir /S /B linktest
D:\svn_wc\testreporsitory\trunk\linktest\source1
D:\svn_wc\testreporsitory\trunk\linktest\source2
D:\svn_wc\testreporsitory\trunk\linktest\target
D:\svn_wc\testreporsitory\trunk\linktest\target\linktarget1.txt
D:\svn_wc\testreporsitory\trunk\linktest\target\linktarget2.txt
 
>svn add linktest
A linktest
A linktest\source1
A linktest\source2
A linktest\target
A linktest\target\linktarget1.txt
A linktest\target\linktarget2.txt
 
>svn commit -m "dirs and files" linktest
Adding linktest
Adding linktest\source1
Adding linktest\source2
Adding linktest\target
Adding linktest\target\linktarget1.txt
Adding linktest\target\linktarget2.txt
Transmitting file data ..
Committed revision 21.
 
>svn propset svn:externals "^/trunk/linktest/target/linktarget1.txt
linksource1.txt" linktest/source1
property 'svn:externals' set on 'linktest\source1'
 
>svn propset svn:externals "^/trunk/linktest/target/linktarget1.txt
linksource1.txt" linktest/source2
property 'svn:externals' set on 'linktest\source2'
 
Attention: this leads to Bug 3518; commit first and update than to avoid
the bug!
------------------------------------------------------------------------
---------
 
>svn update linktest
Fetching external item into 'linktest\source2\linksource1.txt'
E linktest\source2\linksource1.txt
Updated external to revision 21.
Fetching external item into 'linktest\source1\linksource1.txt'
E linktest\source1\linksource1.txt
Updated external to revision 21.
Updated to revision 21.
 
>svn commit linktest -m "Adding first links"
Sending linktest\source1
Sending linktest\source2
Committed revision 22.
 
>svn copy D:\svn_wc\testreporsitory\trunk\linktest
D:\svn_wc\testreporsitory\branches\linktest
A D:\svn_wc\testreporsitory\branches\linktest
 
>svn commit -m "branching" ..\branches\linktest
Adding branches\linktest
Adding branches\linktest\source1
Adding branches\linktest\source1\linksource1.txt
svn: Commit failed (details follow):
svn:
'/svn/testrepository/!svn/bc/21/trunk/linktest/source1/linksource1.txt'
path not found
>svn update ../branaches/linktest
Skipped '..\branaches\linktest'
 
>svn update ../branches/linktest
At revision 22.
 
Some changes happened between 22 and 24 to avoid 3518 so this commit can
be executed...
------------------------------------------------------------------------
---------------
 
>svn commit -m "branching" ..\branches\linktest
Adding branches\linktest
Committed revision 25.
 
cd /D D:\svn_wc2\testrepository\branches\linktest
 
>svn merge D:\svn_wc2\testrepository\trunk\linktest
 
>svn diff
Property changes on: .
___________________________________________________________________
Added: svn:mergeinfo
   Merged /trunk/linktest:r25
 
Property changes on: source1
___________________________________________________________________
Added: svn:mergeinfo
   Merged /trunk/linktest/source1:r25*
 
Property changes on: source1\linksource1.txt
___________________________________________________________________
Added: svn:mergeinfo
   Merged /trunk/linktest/source1/linksource1.txt:r25
 
Property changes on: source2
___________________________________________________________________
Added: svn:mergeinfo
   Merged /trunk/linktest/source2:r25*
 
Property changes on: source2\linksource1.txt
___________________________________________________________________
Added: svn:mergeinfo
   Merged /trunk/linktest/source2/linksource1.txt:r25

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

To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
Received on 2009-11-04 10:00:38 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.