[Bug 15190] New: Bad utf8 decode to unapi and fixing blank screen error status
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Bug ID: 15190 Summary: Bad utf8 decode to unapi and fixing blank screen error status Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: trivial Priority: P5 - low Component: Web services Assignee: koha-bugs@lists.koha-community.org Reporter: hector.hecaxmmx@gmail.com QA Contact: testopia@bugs.koha-community.org Fix bad utf8 decoding, also fix cgi->header(-status) to redirect to one of the posible error pages in /cgi-bin/koha/errors/ -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 --- Comment #1 from Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> --- Created attachment 44861 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=44861&action=edit 15190 - Bad utf8 decode to unapi and fixing blank screen error status Fix bad utf8 decoding, also fix cgi->header(-status) to redirect to one of the posible error pages in /cgi-bin/koha/errors/ To test 1) Copy from LOC (Z39.50) ISBN 8467020113 2) Open URL cgi-bin/koha/unapi?id=koha:biblionumber:4&format=marcxml 3) (enter the new biblionumber for ISBN 8467020113) 4) A marcxml record will display, notice about the bad utf8 decoding characters 5) Search the record in opac and try to save in Zotero (see bad decoding) delete record from Zotero. 6) To reproduce blank screen (error status) play with: cgi-bin/koha/unapi?id=koha:biblionumber:4 cgi-bin/koha/unapi?id=koha:biblionumber:4&format= cgi-bin/koha/unapi?id=koha:biblionumber:4&format=none cgi-bin/koha/unapi?id=koha:biblionumber:&format=marcxml cgi-bin/koha/unapi?&format=oai_dc cgi-bin/koha/unapi? 7) If possible test in NORMARC (UNIMARC will launch an error because bug 15162) -Apply patch -Follow steps 2 to 6 -You will see no errors in utf8 and redirection to one of the error pages in /cgi-bin/koha/errors/ -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #44861|0 |1 is obsolete| | --- Comment #2 from Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> --- Created attachment 44887 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=44887&action=edit Bug 15190: Bad utf8 decode to unapi and fixing blank screen error status Fix bad utf8 decoding, also fix cgi->header(-status) to redirect to one of the posible error pages in /cgi-bin/koha/errors/ To test 1) Copy from LOC (Z39.50) ISBN 8467020113 2) Open URL cgi-bin/koha/unapi?id=koha:biblionumber:4&format=marcxml 3) (enter the new biblionumber for ISBN 8467020113) 4) A marcxml record will display, notice about the bad utf8 decoding characters 5) Search the record in opac and try to save in Zotero (see bad decoding) 6) To reproduce blank screen (error status) play with: cgi-bin/koha/unapi?id=koha:biblionumber:4 cgi-bin/koha/unapi?id=koha:biblionumber:4&format= cgi-bin/koha/unapi?id=koha:biblionumber:4&format=none cgi-bin/koha/unapi?id=koha:biblionumber:&format=marcxml cgi-bin/koha/unapi?&format=oai_dc cgi-bin/koha/unapi? 7) If possible test in NORMARC (UNIMARC will launch an error because bug 15162) -Apply patch -Follow steps 2 to 6 -You will see no errors in utf8 and redirection to one of the error pages in /cgi-bin/koha/errors/ -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |hector.hecaxmmx@gmail.com |ity.org | -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Marc Véron <veron@veron.ch> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |veron@veron.ch --- Comment #3 from Marc Véron <veron@veron.ch> --- Hi Hector, I could reproduce the blank screen issue and it is resolved with your patch. Regarding the bad utf8 encoding (#4 in test plan), can you give a hint on what is wrong? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 --- Comment #4 from Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> --- (In reply to Marc Véron from comment #3)
Hi Hector, I could reproduce the blank screen issue and it is resolved with your patch.
Regarding the bad utf8 encoding (#4 in test plan), can you give a hint on what is wrong?
Hi Marc, for me the patch works well, maybe I need to reword message of commit. Let me improve. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #44887|0 |1 is obsolete| | --- Comment #5 from Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> --- Created attachment 45427 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=45427&action=edit Bug 15190: Bad utf8 decode to unapi and fixing blank screen error status Fix bad utf8 decoding, also fix cgi->header(-status) to redirect to one of the posible error pages in /cgi-bin/koha/errors/ To reproduce the issue in OPAC 1) Copy from LOC (Z39.50) ISBN 8467020113 or test it with whichever record with special characters 2) Open URL in OPAC cgi-bin/koha/unapi?id=koha:biblionumber:4&format=marcxml 3) Enter the new biblionumber for ISBN 8467020113 or the record of your choise 4) A marcxml record will display, notice about the bad utf8 decoding characters 5) Search the record in opac and try to save in Zotero (see bad decoding) 6) To reproduce blank screen (error status) play with: cgi-bin/koha/unapi?id=koha:biblionumber:4&format= cgi-bin/koha/unapi?id=koha:biblionumber:4&format=none cgi-bin/koha/unapi?id=koha:biblionumber:&format=marcxml cgi-bin/koha/unapi?&format=oai_dc 7) If possible test in NORMARC (UNIMARC will launch an error because bug 15162) Test plan -Apply patch -Follow steps 2 to 6 -You will see no errors in utf8 and redirection to one of the error pages in /cgi-bin/koha/errors/ -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 --- Comment #6 from Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> --- (In reply to Marc Véron from comment #3)
Regarding the bad utf8 encoding (#4 in test plan), can you give a hint on what is wrong?
Ahh.. Ok I understand the deconding problem only happend with oai_dc, srw_dc, mods, mods-full, mods3, mods3-full, rdfdc The format marcxml works well doesn't have utf8 decoding problem. <dc:title>AntologÃÂa de entremeses del Siglo de Oro /</dc:title><dc:creator> Arellano, Ignacio. </dc:creator><dc:creator> GarcÃÂa Valdés, Celsa Carmen, ed. </dc:creator> If you apply the patch <dc:title>Antología de entremeses del Siglo de Oro /</dc:title><dc:creator> Arellano, Ignacio. </dc:creator><dc:creator> García Valdés, Celsa Carmen, ed. </dc:creator> I saw the problem in 3.14 or 3.16 but I think in some way someone corrected the problem, Zotero take metadata from marcxml. Whe i was testing this bug I only tested with oai_dc, srw_dc and rdfdc. That's my mistake -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #45427|0 |1 is obsolete| | --- Comment #7 from Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> --- Created attachment 45428 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=45428&action=edit Bug 15190: Bad utf8 decode to unapi and fixing blank screen error status Fix bad utf8 decoding, also fix cgi->header(-status) to redirect to one of the posible error pages in /cgi-bin/koha/errors/ To reproduce the issue in OPAC 1) Copy from LOC (Z39.50) ISBN 8467020113 or test it with whichever record with special characters 2) Open URL in OPAC cgi-bin/koha/unapi?id=koha:biblionumber:4&format=oai_dc play with oai_dc, srw_dc, mods, mods-full, mods3, mods3-full, rdfdc. Note: marcxml does not fail 3) Enter the new biblionumber for ISBN 8467020113 or the record of your choise 4) An oai_dc record will display, notice about the bad utf8 decoding characters 5) Search the record in OPAC 6) To reproduce blank screen (error status) play with: cgi-bin/koha/unapi?id=koha:biblionumber:4&format= cgi-bin/koha/unapi?id=koha:biblionumber:4&format=none cgi-bin/koha/unapi?id=koha:biblionumber:&format=oai_dc cgi-bin/koha/unapi?&format=oai_dc 7) If possible test in NORMARC (UNIMARC will launch an error because bug 15162) Test plan -Apply patch -Follow steps 2 to 6 -You will see no errors in utf8 and redirection to one of the error pages in /cgi-bin/koha/errors/ -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Marc Véron <veron@veron.ch> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #45428|0 |1 is obsolete| | --- Comment #8 from Marc Véron <veron@veron.ch> --- Created attachment 45432 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=45432&action=edit Bug 15190: Bad utf8 decode to unapi and fixing blank screen error status Fix bad utf8 decoding, also fix cgi->header(-status) to redirect to one of the posible error pages in /cgi-bin/koha/errors/ To reproduce the issue in OPAC 1) Copy from LOC (Z39.50) ISBN 8467020113 or test it with whichever record with special characters 2) Open URL in OPAC cgi-bin/koha/unapi?id=koha:biblionumber:4&format=oai_dc play with oai_dc, srw_dc, mods, mods-full, mods3, mods3-full, rdfdc. Note: marcxml does not fail 3) Enter the new biblionumber for ISBN 8467020113 or the record of your choise 4) An oai_dc record will display, notice about the bad utf8 decoding characters 5) Search the record in OPAC 6) To reproduce blank screen (error status) play with: cgi-bin/koha/unapi?id=koha:biblionumber:4&format= cgi-bin/koha/unapi?id=koha:biblionumber:4&format=none cgi-bin/koha/unapi?id=koha:biblionumber:&format=oai_dc cgi-bin/koha/unapi?&format=oai_dc 7) If possible test in NORMARC (UNIMARC will launch an error because bug 15162) Test plan -Apply patch -Follow steps 2 to 6 -You will see no errors in utf8 and redirection to one of the error pages in /cgi-bin/koha/errors/ -- Bad formatting reproduced e.g. with format=srw_dc, blank page reproduced with oai_dc, after applying patch formatting and redirect to error page OK Signed-off-by: Marc Véron <veron@veron.ch> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Marc Véron <veron@veron.ch> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |gmcharlt@gmail.com, | |jonathan.druart@bugs.koha-c | |ommunity.org --- Comment #9 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Looks good to me, but I don't have enough expertise in this script to be 100% confident with the changes. Galen, could we get your opinion on this patch please? I am not sure about 2 points: - replace printing header with a redirect - move error 406 to 400 -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |m.de.rooy@rijksmuseum.nl QA Contact|testopia@bugs.koha-communit |m.de.rooy@rijksmuseum.nl |y.org | Patch complexity|--- |Small patch -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA --- Comment #10 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Hector: Thanks for your patch. I think we still need some changes before moving this to PQA: [1] The encoding problem is imo concentrated in these lines: Around line 155 we should do: print $cgi->header( -type =>'application/xml', -charset => 'UTF-8' ); Add the character set ! (Maybe this is needed a few times more..) Around line 147 we should use chars instead of toString: # $content = $record_dom->toString(); $content = $transformer->output_as_chars( $record_dom ); According to my testing that should resolve the encoding problem. Note that I would prefer to stick to the binmode statement and not add the decodes. [2] The change from 406 to 400 is arguable. Why change it now? [3] Do not redirect to other Koha scripts. This is a separate unAPI implementation. What does unAPI exactly say about such statuses? (I could not reach its site for now..) Note that the browser may affect the results displayed too. I saw differences here between FF and IE. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 --- Comment #11 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- http://code4lib.org/files/unapi_revision_1-14.html https://www.google.nl/url?sa=t&rct=j&q=&esrc=s&source=web&cd=4&ved=0ahUKEwjFvafUzPbJAhWCDhoKHarGDJUQFgg4MAM&url=https%3A%2F%2Fir.library.oregonstate.edu%2Fxmlui%2Fbitstream%2Fhandle%2F1957%2F2359%2Fintro-unapi-draftV15.doc%3Fsequence%3D8&usg=AFQjCNEGxssbXiRQmzUPElGJkGQd1hjx5w&bvm=bv.110151844,d.bGQ -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Bad utf8 decode to unapi |Bad utf8 decode to unapi |and fixing blank screen |and fixing error status 200 |error status |for unapi with no | |parameters --- Comment #12 from Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> --- Thank you very much, Marcel. I've changed the name of the bug according with the info you sent me. I make the changes that you recommend it. I only changed the 200 Ok status if no parameters passed to script. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Bad utf8 decode to unapi |Bad utf8 decode to unapi |and fixing error status 200 |and fixing code status 200 |for unapi with no | |parameters | -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #45432|0 |1 is obsolete| | --- Comment #13 from Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> --- Created attachment 46513 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=46513&action=edit Bug 15190: Bad utf8 decode to unapi and fixing status code 200 Fix bad utf8 decoding, also fix status code 200 for no parameters passed to script To reproduce the issue in OPAC 1) Copy from LOC (Z39.50) ISBN 8467020113 or test it with whichever record with special characters 2) Open URL in OPAC cgi-bin/koha/unapi?id=koha:biblionumber:4&format=oai_dc play with oai_dc, srw_dc, mods, mods-full, mods3, mods3-full, rdfdc. Note: marcxml does not fail 3) Enter the new biblionumber for ISBN 8467020113 or the record of your choise 4) An oai_dc record will display, notice about the bad utf8 decoding characters 5) Search the record in OPAC 6) To reproduce code 200 Ok and 300 Multiple choices play with: cgi-bin/koha/unapi cgi-bin/koha/unapi?id=koha:biblionumber:4 7) If possible test in NORMARC (UNIMARC will launch an error because bug 15162) Test plan -Apply patch -Follow steps 2 to 6 -You will see no errors in utf8 -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 --- Comment #14 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Great, Hector. Marc: if you can your signoff again, I can QA again.. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 --- Comment #15 from Marc Véron <veron@veron.ch> --- Hi Héctor, The encoding is OK with the newest patch for example with: cgi-bin/koha/unapi?id=koha:biblionumber:45100&format=oai_dc (tested with all of: oai_dc, srw_dc, mods, mods-full, mods3, mods3-full, rdfdc) What should happen if I do: cgi-bin/koha/unapi?id=koha:biblionumber:45100&format=xxx cgi-bin/koha/unapi?id=koha:biblionumber:45100&format= What should happen if I use a biblionumber that does not exist? cgi-bin/koha/unapi?id=koha:biblionumber:999999999&format=oai_dc At the moment I get a blank page for all cases. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 --- Comment #16 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- (In reply to Marc Véron from comment #15)
Hi Héctor,
The encoding is OK with the newest patch for example with: cgi-bin/koha/unapi?id=koha:biblionumber:45100&format=oai_dc (tested with all of: oai_dc, srw_dc, mods, mods-full, mods3, mods3-full, rdfdc)
What should happen if I do:
cgi-bin/koha/unapi?id=koha:biblionumber:45100&format=xxx cgi-bin/koha/unapi?id=koha:biblionumber:45100&format=
What should happen if I use a biblionumber that does not exist? cgi-bin/koha/unapi?id=koha:biblionumber:999999999&format=oai_dc
At the moment I get a blank page for all cases.
Blank page is not an error. Unapi should return a http status code for bad requests. See comment11 -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 --- Comment #17 from Héctor Eduardo Castro Avalos <hector.hecaxmmx@gmail.com> --- (In reply to Marcel de Rooy from comment #16) Hi Marc Thank you for keep testing. As Marcel comments the way of the bug has change since the documentation in comment 11. ( I was in a mistake)
(In reply to Marc Véron from comment #15)
What should happen if I do:
cgi-bin/koha/unapi?id=koha:biblionumber:45100&format=xxx cgi-bin/koha/unapi?id=koha:biblionumber:45100&format=
According with the first revision, the unapi must return an code status 300 multiple choice.
What should happen if I use a biblionumber that does not exist? cgi-bin/koha/unapi?id=koha:biblionumber:999999999&format=oai_dc
This must return a 400 or 404 code.
At the moment I get a blank page for all cases.
Blank page is not an error. Unapi should return a http status code for bad requests. See comment11
Regards -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 --- Comment #18 from Marc Véron <veron@veron.ch> --- Hi Héctor, i did more testing: cgi-bin/koha/unapi?id=koha:biblionumber:45100&format=xxx cgi-bin/koha/unapi?id=koha:biblionumber:45100&format= Result for both: 406 invalid format requested Empty page http://10.0.0.62/cgi-bin/koha/unapi?id=koha:biblionumber:999999999&format=oai_dc Result: 404 record not found Empty page http://10.0.0.62/cgi-bin/koha/unapi?id=koha:biblionumber:xxxxxxxxxxxxx&format=oai_dc Result: 404 record not found Empty page http://10.0.0.62/cgi-bin/koha/unapi?id=koha:blabla:1&format=oai_dc Result: 404 record not found Empty page http://10.0.0.62/cgi-bin/koha/unapi?id=koha:biblionumber:1xxxxxxxxxxxxx&format=oai_dc Result: 200 OK Page beginning with: oai_dc:dc xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd"> (...) Same as with koha:biblionumber:1 (existing number) http://10.0.0.62/cgi-bin/koha/unapi?id= Result: 300 multiple choices Page beginning with: <formats id=""><format name="marcxml" type="application/xml" (...) -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 --- Comment #19 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Marc: This looks reasonable to me. Note that the biblionumber is extracted like this: if ($id =~ /koha:biblionumber:(\d+)/) { my $biblionumber = $1; This is current behavior and could be considered as outside the scope of this report.. The id= (empty) case is actually the same as without any parameters. So should present formats. I do not have a problem with the 406; this particular case was a 400. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Marc Véron <veron@veron.ch> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #46513|0 |1 is obsolete| | --- Comment #20 from Marc Véron <veron@veron.ch> --- Created attachment 46574 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=46574&action=edit Bug 15190: Bad utf8 decode to unapi and fixing status code 200 Fix bad utf8 decoding, also fix status code 200 for no parameters passed to script To reproduce the issue in OPAC 1) Copy from LOC (Z39.50) ISBN 8467020113 or test it with whichever record with special characters 2) Open URL in OPAC cgi-bin/koha/unapi?id=koha:biblionumber:4&format=oai_dc play with oai_dc, srw_dc, mods, mods-full, mods3, mods3-full, rdfdc. Note: marcxml does not fail 3) Enter the new biblionumber for ISBN 8467020113 or the record of your choise 4) An oai_dc record will display, notice about the bad utf8 decoding characters 5) Search the record in OPAC 6) To reproduce code 200 Ok and 300 Multiple choices play with: cgi-bin/koha/unapi cgi-bin/koha/unapi?id=koha:biblionumber:4 7) If possible test in NORMARC (UNIMARC will launch an error because bug 15162) Test plan -Apply patch -Follow steps 2 to 6 -You will see no errors in utf8 Followed test plan, works as expected. Signed-off-by: Marc Véron <veron@veron.ch> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Marc Véron <veron@veron.ch> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15190 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #46574|0 |1 is obsolete| | --- Comment #21 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 46581 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=46581&action=edit Bug 15190: Bad utf8 decode to unapi and fixing status code 200 Fix bad utf8 decoding, also fix status code 200 for no parameters passed to script To reproduce the issue in OPAC 1) Copy from LOC (Z39.50) ISBN 8467020113 or test it with whichever record with special characters 2) Open URL in OPAC cgi-bin/koha/unapi?id=koha:biblionumber:4&format=oai_dc play with oai_dc, srw_dc, mods, mods-full, mods3, mods3-full, rdfdc. Note: marcxml does not fail 3) Enter the new biblionumber for ISBN 8467020113 or the record of your choise 4) An oai_dc record will display, notice about the bad utf8 decoding characters 5) Search the record in OPAC 6) To reproduce code 200 Ok and 300 Multiple choices play with: cgi-bin/koha/unapi cgi-bin/koha/unapi?id=koha:biblionumber:4 7) If possible test in NORMARC (UNIMARC will launch an error because bug 15162) Test plan -Apply patch -Follow steps 2 to 6 -You will see no errors in utf8 Followed test plan, works as expected. Signed-off-by: Marc Veron <veron@veron.ch> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org