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

Minor buglet: confusing error message

From: Jeff Squyres <jsquyres_at_open-mpi.org>
Date: 2005-05-01 13:10:10 CEST

Greetings. I have a minor usability feature request: we have found a
confusing error message that threw off one of my developers when it
occurred. This is certainly not a big deal, but it would be nice if it
could be fixed in future versions.

The problem occurs when you try to do any repository-based command
(such as "svn up") in a working directory that corresponds to a URL
that no longer exists. For example, if you have a working directory of
a temporary branch, and that temporary branch is removed in the
repository, and then you try to "svn up", you'll get back the following
message (this is from 1.2.0rc2):

svn: Cannot replace a directory from within

This is somewhat confusing -- it doesn't give any indication that the
URL corresponding to your working directory no longer exists. Could
this message be updated? Thanks!

Here's a simple scriptlet to reproduce the problem:

-----
#!/bin/sh

if test -z "$TMPDIR"; then
     BASE="/tmp"
else
     BASE="$TMPDIR"
fi
BASE="$BASE/svn-test.`whoami`"

rm -rf "$BASE"
mkdir "$BASE"
cd "$BASE"

svnadmin create test-repo
REPO="file:///$BASE/test-repo"
svn co "$REPO" working-copy
cd working-copy

# r1
mkdir trunk branches
svn add trunk branches
svn ci -m "add trunk and branches"

# r2
cd trunk
mkdir foo
touch foo/bar
svn add foo
svn ci foo -m "add foo"

# r3
svn cp . "$REPO/branches/foo-branch" -m "copy"

cd "$BASE"
svn co "$REPO/branches/foo-branch" working-branch
svn rm "$REPO/branches/foo-branch" -m "remove"
cd working-branch
svn up

# Don't forget to cleanup...
#rm -rf "$BASE"
-----

Thanks!

-- 
{+} Jeff Squyres
{+} The Open MPI Project
{+} http://www.open-mpi.org/
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Sun May 1 13:12:22 2005

This is an archived mail posted to the Subversion Users mailing list.