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

Re: Tree conflict bug?

From: Mark Phippard <markphip_at_gmail.com>
Date: Thu, 30 Oct 2008 14:48:59 -0400

On Thu, Oct 30, 2008 at 2:04 AM, Neels J Hofmeyr <neels_at_elego.de> wrote:
>
>
> Mark Phippard wrote:
>> On Wed, Oct 29, 2008 at 9:38 PM, Neels J. Hofmeyr <neels_at_elego.de> wrote:
>>> Just re-iterating: When you run Revert, I'd expect it to become the reverted
>>> state before the tree-conflict, i.e. the old base without local mods. Which
>>> is kind of not what sentient users might expect at all.
>>
>> For a user to want or expect that behavior would seem that they would
>> have to just ignore what an update command does. If I run update does
>> it update or not? If it does, then the file ought to reflect the
>> state of the repository -- unversioned. Of course perhaps we need to
>> invent a new "state" for this scenario, but if we have to choose from
>> our existing states I think unversioned is the one that reflects the
>> reality of the situation. It also puts the working copy in the best
>> place to resolve the conflict as the user can run svn add or "rm" to
>> put the WC into the desired state. In this scenario, it probably
>> makes sense for the parent folder to be in the tree conflict state?
>>
>
> A quick response on this:
>
> You are right, the behaviour you are describing is definitely wrong. Do you
> still have the commands to reproduce the error?

So here is a transcript I just made.

$ svn --version
svn, version 1.6.0 (dev build)
   compiled Oct 30 2008, 14:36:18

Copyright (C) 2000-2008 CollabNet.
Subversion is open source software, see http://subversion.tigris.org/
This product includes software developed by CollabNet (http://www.Collab.Net/).

The following repository access (RA) modules are available:

* ra_neon : Module for accessing a repository via WebDAV protocol using Neon.
  - handles 'http' scheme
  - handles 'https' scheme
* ra_svn : Module for accessing a repository using the svn network protocol.
  - with Cyrus SASL authentication
  - handles 'svn' scheme
* ra_local : Module for accessing a repository on local disk.
  - handles 'file' scheme
* ra_serf : Module for accessing a repository via WebDAV protocol using serf.
  - handles 'http' scheme
  - handles 'https' scheme

$ cd ~
$ mkdir tree-conflicts
$ cd tree-conflicts/
$ svnadmin create repos
$ svn co file://`pwd`/repos wc1
Checked out revision 0.
$ echo "File 123" > wc1/foo
$ svn add wc1/foo
A wc1/foo
$ svn ci -m "Add foo" wc1/
Adding wc1/foo
Transmitting file data .
Committed revision 1.
$ svn co file://`pwd`/repos wc2
A wc2/foo
Checked out revision 1.
$ svn up wc1
At revision 1.
svn$ svn move wc1/foo wc1/bar
A wc1/bar
D wc1/foo
$ svn ci -m "Rename foo to bar" wc1
Adding wc1/bar
Deleting wc1/foo

Committed revision 2.
$ echo "Edit foo" >> wc2/foo
$ svn st wc2
M wc2/foo
$ svn up wc2
   C wc2/foo
A wc2/bar
Updated to revision 2.
Summary of conflicts:
  Tree conflicts: 1
$ svn st wc2
M C wc2/foo
$ svn resolved wc2
Resolved conflicted state of 'wc2'
$ svn st wc2
M wc2/foo
$ svn ci -m "Cannot checkin" wc2Sending wc2/foo
subversion/libsvn_client/commit.c:864: (apr_err=160013)
svn: Commit failed (details follow):
subversion/libsvn_fs_fs/tree.c:661: (apr_err=160013)
svn: File not found: transaction '2-2', path '/foo'
$ svn add wc2/foo
svn: warning: 'wc2/foo' is already under version control
$ svn st wc2
M wc2/foo
$ svn add --force wc2/foo
$ svn st wc2
M wc2/foo
$ svn ci -m "Cannot checkin" wc2Sending wc2/foo
subversion/libsvn_client/commit.c:864: (apr_err=160013)
svn: Commit failed (details follow):
subversion/libsvn_fs_fs/tree.c:661: (apr_err=160013)
svn: File not found: transaction '2-3', path '/foo'
$ svn rm wc2/foo
subversion/svn/util.c:860: (apr_err=195006)
svn: Use --force to override this restriction
subversion/libsvn_client/delete.c:65: (apr_err=195006)
svn: 'wc2/foo' has local modifications
$ svn revert wc2/foo
Reverted 'wc2/foo'
$ svn info wc2/foo
Path: wc2/foo
Name: foo
URL: file:///Users/mphippard/tree-conflicts/repos/foo
Repository Root: file:///Users/mphippard/tree-conflicts/repos
Repository UUID: 67048387-9e2d-479b-8f38-28271a7f8fe3
Revision: 2
Node Kind: file
Schedule: normal
Last Changed Author: mphippard
Last Changed Rev: 1
Last Changed Date: 2008-10-30 14:40:12 -0400 (Thu, 30 Oct 2008)
Text Last Updated: 2008-10-30 14:44:44 -0400 (Thu, 30 Oct 2008)
Checksum: bc6defbfcce1638222800efc165b204c

$ svn rm wc2/foo
D wc2/foo
$ svn ci -m "Cannot delete" wc2
Deleting wc2/foo
subversion/libsvn_client/commit.c:864: (apr_err=160028)
svn: Commit failed (details follow):
subversion/libsvn_repos/commit.c:124: (apr_err=160028)
svn: File or directory '/foo' is out of date
$ svn up wc2
At revision 2.
$ svn ci -m "Cannot delete" wc2
Deleting wc2/foo
subversion/libsvn_client/commit.c:864: (apr_err=160028)
svn: Commit failed (details follow):
subversion/libsvn_repos/commit.c:124: (apr_err=160028)
svn: File or directory '/foo' is out of date

-- 
Thanks
Mark Phippard
http://markphip.blogspot.com/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: dev-help_at_subversion.tigris.org
Received on 2008-10-30 19:49:17 CET

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