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

RE: svn commit: r1655474 - /subversion/trunk/subversion/tests/cmdline/redirect_tests.py

From: Bert Huijben <bert_at_qqmail.nl>
Date: Thu, 29 Jan 2015 10:04:55 +0100

> -----Original Message-----
> From: Philip Martin [mailto:philip.martin_at_wandisco.com]
> Sent: donderdag 29 januari 2015 00:49
> To: dev_at_subversion.apache.org
> Subject: Re: svn commit: r1655474 -
> /subversion/trunk/subversion/tests/cmdline/redirect_tests.py
>
> rhuijben_at_apache.org writes:
>
> > Author: rhuijben
> > Date: Wed Jan 28 21:28:07 2015
> > New Revision: 1655474
> >
> > URL: http://svn.apache.org/r1655474
> > Log:
> > Following up on r1655458, update expected results in redirect tests.
> > (This file was missing from that patch)
> >
> > * subversion/tests/cmdline/redirect_tests.py
> > (redirected_copy): Split test. Update expected result.
> >
> > Modified:
> > subversion/trunk/subversion/tests/cmdline/redirect_tests.py
> >
> > Modified: subversion/trunk/subversion/tests/cmdline/redirect_tests.py
> > URL:
>
http://svn.apache.org/viewvc/subversion/trunk/subversion/tests/cmdline/redir
> ect_tests.py?rev=1655474&r1=1655473&r2=1655474&view=diff
> >
> ================================================================
> ==============
> > --- subversion/trunk/subversion/tests/cmdline/redirect_tests.py
(original)
> > +++ subversion/trunk/subversion/tests/cmdline/redirect_tests.py Wed Jan
28
> 21:28:07 2015
> > @@ -211,10 +211,18 @@ def redirected_copy(sbox):
> >
> > sbox.build(create_wc=False)
> >
> > + # This tests the actual copy handling
> > expected_error = "svn: E175011: Repository moved permanently"
> > svntest.actions.run_and_verify_svn(None, None, expected_error,
> > 'cp', '-m', 'failed copy',
> > sbox.redirected_root_url() + '/A',
> > + sbox.redirected_root_url() +
'/A_copied')
> > +
> > + # This tests the cmdline handling of '^/copy-of-A'
> > + expected_error = "svn: E155007: Resolving '\^/': no repository root
found"
> > + svntest.actions.run_and_verify_svn(None, None, expected_error,
> > + 'cp', '-m', 'failed copy',
> > + sbox.redirected_root_url() + '/A',
> > '^/copy-of-A')
> >
>
> With 1.8 I get:
>
> $ svn cp -mm http://localhost:8888/obj/PERM/repo/A ^/copy
> svn: E175011: Repository moved permanently to
> 'http://localhost:8888/obj/repo/A'; please relocate
>
> with trunk I get:
>
> $ svn cp -mm http://localhost:8888/obj/PERM/repo/A ^/copy
> svn: E155007: Resolving '^/': no repository root found in the target
arguments
> or in the current directory
>
> which is a rubbish error message. The point of this test is that it
> should report E175011 to show the relocated URL to the user.

That is what you get when we mix two features without a proper design.

The commandline parser +- ignores every error it gets from
svn_client_get_repos_root(), telling you that it failed to obtain a
repository root.

And redirects were just added as nice feature for during svn update.

(And you really don't want to know how you got the 'nice' error in 1.8 /
trunk before the recent patches... It was somewhere halfway doing a http-v1
protocol handshake on the pre-redirect location, after leaving an ra-session
in an dangling state after the initial open operation)

Getting a better message here, requires a better implementation in svn-s
commandline argument processing. It should ask for redirect information and
then use that to inform the user.

>
> I note another problem with trunk:
>
> $ svn ls http://localhost:8888/obj/PERM/repo/A
> Redirecting to URL 'pB#.':
> svn: E170000: Illegal repository URL 'pB#.'

Thanks for fixing this one.

        Bert
Received on 2015-01-29 10:05:32 CET

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.