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

working copy failure

From: Greg Stein <gstein_at_lyra.org>
Date: 2003-10-22 13:40:00 CEST

Hoo... I just ran into a fun problem here. My SVN working copy is set up
like so:

  svn/
    tools/
      dev/ wc_format == 1
        iz/ wc_format == 2

I've added a script to the iz/ subdirectory, along with setting the
svn:executable property.

All seems fine, now I try to commit:

[gstein@roshi iz]$ svn commit -F ../svn-commit.tmp
Sending iz/find-fix.py
Adding iz/run-queries.sh
subversion/libsvn_client/commit.c:736: (apr_err=2)
svn: No such file or directory
svn: Commit failed (details follow):
subversion/libsvn_subr/io.c:237: (apr_err=2)
svn: svn_io_copy_file: error copying
'/home/gstein/src/svn/tools/dev/iz/.svn/props/run-queries.sh' to
'/home/gstein/src/svn/tools/dev/iz/.svn/tmp/props/run-queries.sh.5.tmp'
[gstein@roshi iz]$

For those "in the know", they'd say, "hey! where is the .svn-work on that
props file?" Good point. Where is it? Well... it appears that the commit
process sees the *parent's* wc_format and assumes that is the format of
the child. So it loses the .svn-work suffix and promptly barfs.

To be a bit more specific, the stack looks like:

svn_io_copy_file(
    "/home/gstein/src/svn/tools/dev/iz/.svn/props/run-queries.sh",
    "/home/gstein/src/svn/tools/dev/iz/.svn/tmp/props/run-queries.sh", ...)
svn_wc_transmit_prop_deltas(
    "/home/gstein/src/svn/tools/dev/iz/run-queries.sh", ...)
do_item_commit(...)
path_driver_cb_func(...)
svn_delta_path_driver(...)
svn_client__do_commit(...)

The problematic code is svn_wc_transmit_prop_deltas() where it calls
svn_wc__prop_path(). It passes an adm_access that corresponds to the
parent directory, rather than the dir for 'path'. The underlying
__prop_path() code doesn't take this into account when it builds the path
(which also includes a test of the wc_format).

I'm not familiar enough with this area to know how to fix up that
svn_wc__adm_wc_format call in adm_files::prop_path_internal().

While it is certainly possible to say, "bah. that happens only to people
with an old wc format directory," then I'd respond with "if our format
stuff doesn't work, then why bother?"

I suspect the answer is to open a new access baton from the given access
baton, then use that appropriately. I'm just not sure of the implications
around that, or the best layer of the onion to do that at.

Cheers,
-g

-- 
Greg Stein, http://www.lyra.org/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Oct 22 13:45:32 2003

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.