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

Re: Mysterious "Transaction is out of date" error

From: Karl Fogel <kfogel_at_newton.ch.collab.net>
Date: 2002-08-05 18:09:34 CEST

Gareth McCaughan <Gareth.McCaughan@pobox.com> writes:
> #!/usr/local/bin/bash -v
> BASE=<some directory or other>
> R=$BASE/svn-r
> W=$BASE/svn-w
> rm -rf $R $W
> svnadmin create $R
> mkdir $W
> cd $W
> mkdir project
> svn import -m 'initial import' file://$R project project
> svn co file://$R/project project

Hmmm. Why didn't that checkout get an `obstructed' error? There's
already a non-wc directory named "project" here, the one you imported
from. Now you're checking out a working copy over (into) it?

I thought we checked for this. Maybe I'm misremembering... ?

(I realize this isn't the main point of your bug report, it's just
something I noticed as I was reading.)

> cd project
> mkdir a
> svn add a
> touch a/b
> svn add a/b
> svn commit -m 'add stuff'
> echo zog >> a/b
> svn commit -m 'extend a/b'
> svn cp a c
> svn commit -m 'duplicate directory'
>
> The final commit fails, thus:
>
> Adding c
> Adding c/b
>
> subversion/libsvn_client/commit.c:662
> svn_error: #21087 : <Transaction is out of date>
> Commit failed (details follow):
>
> subversion/libsvn_ra_local/commit_editor.c:112
> svn_error: #21087 : <Transaction is out of date>
> out of date: `/project/c/b' in txn `4'

Whoa. That seems like a bug to me too.

> In that final commit, "c" gets added happily. Then
> Subversion goes to add "c/b". In "add_file" in "commit_editor.c",
> there's a check that the path of the newly added file doesn't
> already exist; if it does, the "Transaction out of date" error
> is produced. This check fails: the path *does* exist.
>
> Removing the "echo zog" line and the following commit makes
> the error go away: Subversion never does an add_file on
> "c/b".
>
> I'm guessing that when "c" gets added, what's added includes
> the directory entries for its children, which is why "c/b" is
> already there when Subversion goes to add it. But I don't
> understand why removing the modification to "a/b" before
> the copy makes a difference.

Thanks for the analysis!

Can you file a new issue on this (or maybe there already is one --
search a bit before filing).

To answer the question in your last sentence:

I believe when you remove the "echo zog" modification to a/b, you make
the second commit a total no-op w.r.t. the repository. I'll bet that
commit didn't create a new revision, right?

-K

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon Aug 5 18:25:07 2002

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

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.