[Xapian-discuss] Re: 1.0 news, and a call for testing
Fabrice Colin
fabrice.colin at gmail.com
Sun May 6 11:24:55 BST 2007
On 5/6/07, Richard Boulton <richard at lemurconsulting.com> wrote:
> Fabrice Colin wrote:
> > Apart from parsing the actual message, is there an easy way to determine
> > that
> > the DB couldn't be open because the format version is not understood, as
> > opposed
> > to any other case for which a DatabaseOpeningError may be thrown ?
> > What about throwing a DatabaseVersionError exception instead ?
>
> That seems like a reasonable suggestion to me. We want to avoid forcing
> application writers to parse error messages - it's quite reasonable that
> they might want to handle this case differently to any other
> DatabaseOpeningError - for example, if they have the source data
> available still, the application could automatically start rebuilding
> the database, so that software upgrades can work without human
> intervention.
>
That's exactly what I had in mind :-)
> If the cause of the opening error is unknown, it's
> probably not safe for the application to do anything except for display
> the error to a human.
>
> I'll look at putting a patch for this together shortly - I wouldn't
> imagine it would be terribly invasive.
>
Great. Thanks !
Fabrice
More information about the Xapian-discuss
mailing list