You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Stefan Sperling <st...@elego.de> on 2010/07/13 14:44:02 UTC

Re: [PATCH] svn status ^/ foo: The node '/path/to/wc/foo' was not found.

On Sun, Jun 13, 2010 at 06:25:00PM +0200, Uwe Stuehler wrote:
> While testing all kinds of silly argument combinations to find
> inconsistencies in argument handling I found this case where checkout
> reports a bogus error that covers up the real error.
> 
> $ cd /path/to/wc
> $ svn status ^/ foo
> subversion/svn/status-cmd.c:250: (apr_err=155010)
> subversion/svn/util.c:1118: (apr_err=155010)
> subversion/libsvn_client/cmdline.c:269: (apr_err=155010)
> subversion/libsvn_client/cmdline.c:132: (apr_err=155010)
> subversion/libsvn_client/util.c:270: (apr_err=155010)
> subversion/libsvn_client/ra.c:422: (apr_err=155010)
> subversion/libsvn_client/url.c:106: (apr_err=155010)
> subversion/libsvn_client/url.c:151: (apr_err=155010)
> subversion/libsvn_wc/node.c:432: (apr_err=155010)
> subversion/libsvn_wc/wc_db.c:4588: (apr_err=155010)
> subversion/libsvn_wc/wc_db.c:4580: (apr_err=155010)
> svn: The node '/path/to/wc/foo' was not found.
> 
> 
> Index: subversion/libsvn_client/cmdline.c
> ===================================================================
> --- subversion/libsvn_client/cmdline.c    (revision 953325)
> +++ subversion/libsvn_client/cmdline.c    (working copy)
> @@ -123,6 +123,7 @@ check_root_url_of_target(const char **root_url,
>         * argument.
>         */
>        if ((err->apr_err == SVN_ERR_ENTRY_NOT_FOUND)
> +          || (err->apr_err == SVN_ERR_WC_PATH_NOT_FOUND)
>            || (err->apr_err == SVN_ERR_WC_NOT_WORKING_COPY))
>          {
>            svn_error_clear(err);
> 
> With this change svn_cl__status() actually makes it past the
> argument parsing phase:
> 
> $ svn status ^/ foo
> subversion/svn/status-cmd.c:323: (apr_err=155022)
> subversion/svn/util.c:960: (apr_err=155022)
> subversion/libsvn_client/status.c:267: (apr_err=155022)
> svn: Path 'file:///path/to/repo' is not a working copy path

Until issue #3620 is fixed, this patch causes the assertion failure
described there:

$ svn st ^/ foo 
subversion/libsvn_client/cmdline.c:321: (apr_err=235000)
svn: In file 'subversion/libsvn_subr/dirent_uri.c' line 1646: assertion failed (! svn_path_is_url(relative))
Abort trap (core dumped)

But catching SVN_ERR_WC_PATH_NOT_FOUND is clearly in line with the
intended behaviour of check_root_url_of_target(), so I'll commit this.

Thanks!
Stefan