[Koha-bugs] [Bug 33270] OAI-PMH should not die on record errors

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Jun 23 19:00:34 CEST 2023


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33270

--- Comment #10 from Nick Clemens <nick at bywatersolutions.com> ---
(In reply to Marcel de Rooy from comment #7)
> (In reply to David Cook from comment #6)
> > I recently bumped into this problem as well, although I don't try to recover
> > using StripNonXmlChars()... I don't know what I think about sending out a
> > slightly different version than what's stored in the database...
> 
> Agreed.
> Yes, the new code with StripNonXmlChars here in OAI is a bit weird. Either
> we do such a thing in ->record or we dont?
> Probably we dont. So could you only send an error and continue?
> 
> Moving to FQA

We used to do this, see bug 29697

OAI doesn't seem to have errors at the record level, only the request, and they
don't match to what is happening here:
https://www.openarchives.org/OAI/openarchivesprotocol.html#ErrorConditions

(In reply to David Cook from comment #6)
> I recently bumped into this problem as well, although I don't try to recover
> using StripNonXmlChars()... I don't know what I think about sending out a
> slightly different version than what's stored in the database...
> 
> But overall we do need a fix harvests choking on 1 bad record.

It is a bit odd, what we do in staff side is just show it and indiciate it may
be degraded - I propose something similar here - strip them and add an 'about'
section. This seems to be a more general way to send a message


We should ultimately prevent these records from being added to a catalog, but
data can get messy. I restrict this now to a specific exception. I think it's a
better use experience to handle it and warn when we can, rather than rejext
totally.

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list