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

Re: Replacing symlink exhibits unexpected error

From: Stefan Sperling <stsp_at_elego.de>
Date: Tue, 26 Jul 2011 23:19:22 +0200

On Tue, Jul 26, 2011 at 02:10:59PM -0700, Mattius McLaughlin wrote:
> On 07/19/11 12:04, Mattius McLaughlin wrote:
> >Hi All,
> >
> > I'm encountering some strange behaviour with replacing a symlink
> >with a real file in the repository and wanted to know if what I
> >was seeing is a bug or whether I'm doing something wrong. I'd
> >like to replace the file in one commit, but Subversion objects to
> >changing the file type:
> >
> >% ls -l trunk/memory_ddr3.v
> >lrwxrwxrwx 1 mclaughl eng 74 Jul 19 11:51 trunk/memory_ddr3.v ->
> >/proj/ddr3/s39/s39a0c2762e5ac7f7
> >% svn status trunk/memory_ddr3.v
> >% svn rm trunk/memory_ddr3.v
> >D trunk/memory_ddr3.v
> >% cp /proj/ddr3/s39/s39a0c2762e5ac7f7 trunk/memory_ddr3.v
> >% svn add trunk/memory_ddr3.v
> >A trunk/memory_ddr3.v
> >% svn status trunk/memory_ddr3.v
> >R trunk/memory_ddr3.v
> >% svn ci -m "Correcting link" trunk/memory_ddr3.v
> >svn: Commit failed (details follow):
> >svn: Entry '/home/mclaughl/nobackup/trunk/memory_ddr3.v' has
> >unexpectedly changed special status
> >
>
> In case anyone stumbles across this later, the missing step here was
> to remove the svn:special property as well as removing the file:
>
> % ls -l trunk/memory_ddr3.v
> lrwxrwxrwx 1 mclaughl eng 74 Jul 19 11:51 trunk/memory_ddr3.v ->
> /proj/ddr3/s39/s39a0c2762e5ac7f7
> % svn status trunk/memory_ddr3.v
> % svn rm trunk/memory_ddr3.v
> D trunk/memory_ddr3.v
> % svn propdel svn:special trunk/memory_ddr3.v
> property 'svn:special' deleted from 'trunk/memory_ddr3.v'.
> % cp /proj/ddr3/s39/s39a0c2762e5ac7f7 trunk/memory_ddr3.v
> % svn add trunk/memory_ddr3.v
> A trunk/memory_ddr3.v
> % svn status trunk/memory_ddr3.v
> R trunk/memory_ddr3.v
> % svn ci -m "Correcting link" trunk/memory_ddr3.v
> Replacing trunk/memory_ddr3.v
> Transmitting file data .
> Committed revision 20311.
>
> I'm surprised the client can't handle this automatically, but I
> suppose it's a fairly rare use case.

I can reproduce this problem in 1.6.x. I would say it is a bug.

It seems to work fine in 1.7, without the need to delete the
svn:special property first. There's a minor UI problem though,
'svn status' shows the replace as '~' rather than 'R'.
Received on 2011-07-26 23:20:17 CEST

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.