You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Trevor Gerbrand <ge...@willowglen.ca> on 2011/02/14 22:22:49 UTC

bug: svn relocate doesn't update relative externals for individual directories

Hi,
I've run into an issue using svn relocate on a directory that has 
relative svn:externals properties on it.  It is similar to the issue 
that was resolved in Issue 3597 but that only works correctly with a 
completely checked out version of the repository.  I would like to have 
this functionality for checking out a single directory in the repository 
and not have to check out everything.

My repository structure looks like this:

/
/common_files
/application1
/application2

** The common_files directory contains special files that can apply to 
all applications.

** The application directories each have this svn:externals property on 
them:    ../common_files/common.file common.file

If I check out the entire repository from one URL and do an svn relocate 
to another URL it correctly updates the URL for the external file but if 
I only check out application1 from one URL and do an svn relocate to 
another URL the external file still points to the first URL.

This problem only started creeping up because we've changed from using 
the file protocol to access our repositories to using svnserve.  We use 
TortoiseSVN 1.6.12 which uses Subversion 1.6.15.

Could someone confirm that this is a bug  and direct me to what I should 
do next to get it resolved?

Thank you,

-- 
Willowglen Systems Inc. <http://www.willowglen.ca>*Trevor Gerbrand*, E.I.T.
SCADACOM 5 Project Lead
trevor.gerbrand@willowglen.ca <ma...@willowglen.ca>
Tel: +1 780 465 1530 ext 119
Fax: +1 780 465 0130
http://www.willowglen.ca

Re: bug: svn relocate doesn't update relative externals for individual directories

Posted by Daniel Shahaf <d....@daniel.shahaf.name>.
Johan Corveleyn wrote on Mon, Feb 14, 2011 at 23:54:33 +0100:
> Just as an aside: when you mention an issue number, please also add
> the summary of the issue

And a link to it.  (http://subversion.tigris.org/issues/show_bug.cgi?id=3597)

> (makes it easier to get the context, without
> having to look it up). In this case the summary says: "relocate should
> update externals from the same repository, too"
> 
> Though the issue is marked fixed, its Target Milestone says "1.7.0",
> which means it's only fixed in svn's trunk, and will be included in
> the upcoming 1.7 release. It's definitely not included in 1.6.15 (nor
> is it in any other 1.6.x release currently).

... and I'm not sure (without looking up the details) how easy the fix
would be to backport, given that 1.6 and 1.7'c wc libraries are as
similar to each other as the Python sqlite3 module to the Perl one.

> The implementations of file externals and dir externals are quite
> different. File externals are implemented as some variation of a
> "switched" file (that's why they only work for links pointing to the
> same repository).

Johan, FYI, see erratum wc001.txt in trunk (under notes/).

Re: bug: svn relocate doesn't update relative externals for individual directories

Posted by Johan Corveleyn <jc...@gmail.com>.
On Mon, Feb 14, 2011 at 10:22 PM, Trevor Gerbrand
<ge...@willowglen.ca> wrote:
>
> Hi,
> I've run into an issue using svn relocate on a directory that has relative svn:externals properties on it.  It is similar to the issue that was resolved in Issue 3597 but that only works correctly with a completely checked out version of the repository.  I would like to have this functionality for checking out a single directory in the repository and not have to check out everything.
>
> My repository structure looks like this:
>
> /
> /common_files
> /application1
> /application2
>
> ** The common_files directory contains special files that can apply to all applications.
>
> ** The application directories each have this svn:externals property on them:    ../common_files/common.file common.file
>
> If I check out the entire repository from one URL and do an svn relocate to another URL it correctly updates the URL for the external file but if I only check out application1 from one URL and do an svn relocate to another URL the external file still points to the first URL.
>
> This problem only started creeping up because we've changed from using the file protocol to access our repositories to using svnserve.  We use TortoiseSVN 1.6.12 which uses Subversion 1.6.15.
>
> Could someone confirm that this is a bug  and direct me to what I should do next to get it resolved?

Hi,

Just as an aside: when you mention an issue number, please also add
the summary of the issue (makes it easier to get the context, without
having to look it up). In this case the summary says: "relocate should
update externals from the same repository, too"

Though the issue is marked fixed, its Target Milestone says "1.7.0",
which means it's only fixed in svn's trunk, and will be included in
the upcoming 1.7 release. It's definitely not included in 1.6.15 (nor
is it in any other 1.6.x release currently).

So I don't understand why it even works in the first case you
mentioned. Might have something to do with the fact that you're using
a "file external" (pointing to a single file), instead of a "directory
external".

The implementations of file externals and dir externals are quite
different. File externals are implemented as some variation of a
"switched" file (that's why they only work for links pointing to the
same repository). That may explain why it works in the first case (if
the "switched-to" location is also included in your working copy, it
just gets relocated along with everything else maybe?).

HTH,
--
Johan