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

Re: [PATCH] Augment the awful "200 OK" error message when can't connect to repository

From: Ivan Zhakov <ivan_at_visualsvn.com>
Date: Sun, 10 Jan 2010 00:56:32 +0300

On Fri, Jan 8, 2010 at 4:22 PM, Julian Foad <julianfoad_at_btopenworld.com> wrote:
> What happens if I accidentally specify a URL that's not a repository?
> (Recent trunk build, Neon.)
>
>> $ svn checkout https://svn.apache.org/repos/
>> svn: OPTIONS of 'https://svn.apache.org/repos': 200 OK (https://svn.apache.org)
>
> This is a truly awful error message, appearing alone as it does. Google
> reveals that many users have spent hours trying to track down the cause
> of such errors. They appear in all repository operations, not just
> checkout. For example,
> <http://forum.joomla.org/viewtopic.php?f=406&t=205587> (during import;
> unresolved) and
> <http://stackoverflow.com/questions/1025377/an-svn-error-200-ok-when-checking-out-from-my-online-repo> (during checkout; SSH credentials not provided).
>
>
Hi Julian,

Fully agree with you that this message is really confusing.

> What do we need to do? Two things, I think:
>
>  1. That low-level error report needs to be better. Any low-level
> function that regards a "200 OK" response as an error must not just
> create an error object saying "200 OK" alone but must wrap or replace
> that with an error message that indicates what it was trying to do and
> why an "OK" response is wrong.
>
Please consider attached patch to turn 200 OK error message to more
descriptive one:
svn: OPTIONS of 'https://svn.apache.org/repos/': XML parse error at
line 1: no element
found (https://svn.apache.org)

[[[
Improve RA neon error message when non XML response received.

* subversion/libsvn_ra_neon/util.c
  (wrapper_reader_cb): Wrap neon XML parser error.
]]]

PS: Tests are still running.

-- 
Ivan Zhakov
VisualSVN Team

Received on 2010-01-09 22:57:11 CET

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