Bugzilla – Attachment 173089 Details for
Bug 35659
OAI harvester
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 35659: (follow-up) Better handling of accented characters
Bug-35659-follow-up-Better-handling-of-accented-ch.patch (text/plain), 3.12 KB, created by
David Cook
on 2024-10-22 01:36:09 UTC
(
hide
)
Description:
Bug 35659: (follow-up) Better handling of accented characters
Filename:
MIME Type:
Creator:
David Cook
Created:
2024-10-22 01:36:09 UTC
Size:
3.12 KB
patch
obsolete
>From 57754aec2ade563d952bbc5aa0dccab752ac4106 Mon Sep 17 00:00:00 2001 >From: Andreas Roussos <a.roussos@dataly.gr> >Date: Wed, 28 Feb 2024 07:06:33 +0000 >Subject: [PATCH] Bug 35659: (follow-up) Better handling of accented characters >MIME-Version: 1.0 >Content-Type: text/plain; charset=UTF-8 >Content-Transfer-Encoding: 8bit > >If you try to harvest bibliographic records from a UNIMARC OAI >repository (using oai_dc data format) in a MARC21 Koha instance >and run the OAI harvester script in verbose mode, you may get >lines similar to the following in the output: > >no mapping found for [0xC9] at position 0 in Ãconomie politique g0=ASCII_DEFAULT g1=EXTENDED_LATIN at /usr/share/perl5/MARC/Charset.pm line 308. >no mapping found for [0xC9] at position 0 in Ãglise et société g0=ASCII_DEFAULT g1=EXTENDED_LATIN at /usr/share/perl5/MARC/Charset.pm line 308. > >When looking at the imported records' biblio details page in >the OPAC, most words containing accented characters will not >appear correctly. > >The fix is to apply Franck Theeten's solution from Bug 16488 >(https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=16488#c24) >and modify the value of the MARC leader's 10th character >to 'a' in the XSLT that transforms the UNIMARC OAI records >into MARC21 XML. Then, the accented characters get imported >properly and the records appear correctly in the OPAC. > >Test plan: > >0) Without this patch, running the OAI harvesting script in > verbose mode produces many warnings, and garbled characters > appear in the OPAC biblio details page wherever accented > characters are in use. > >1) Apply this patch. > >2) Re-run the OAI harvesting script in verbose + force mode > (force mode is required to ignore record datestamps from > previous runs): > > misc/cronjobs/harvest_oai.pl -v -r <OAI_REPO_ID> -f > > This time there should be no warnings printed on your > screen, and any characters with accents in the updated > records should look OK in the OPAC. > >Thanks-to: Franck Theeten <franck.theeten@africamuseum.be> >Signed-off-by: Michal Denar <black23@gmail.com> >Signed-off-by: Julian Maurice <julian.maurice@biblibre.com> >Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com> >Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net> >Signed-off-by: David Cook <dcook@prosentient.com.au> >Sponsored-by: Association KohaLa - https://koha-fr.org/ >--- > koha-tmpl/intranet-tmpl/prog/en/xslt/OAIDCtoMARC21XML.xsl | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/xslt/OAIDCtoMARC21XML.xsl b/koha-tmpl/intranet-tmpl/prog/en/xslt/OAIDCtoMARC21XML.xsl >index 4e3d13a436..6a7da776a0 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/xslt/OAIDCtoMARC21XML.xsl >+++ b/koha-tmpl/intranet-tmpl/prog/en/xslt/OAIDCtoMARC21XML.xsl >@@ -53,7 +53,7 @@ > <xsl:otherwise>m</xsl:otherwise> > </xsl:choose> > </xsl:variable> >- <xsl:value-of select="concat(' ',$leader06,$leader07,' 3u ')"/> >+ <xsl:value-of select="concat(' ',$leader06,$leader07,' a 3u ')"/> > </xsl:element> > > <datafield tag="042" ind1=" " ind2=" "> >-- >2.39.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 35659
:
160356
|
160357
|
160744
|
161813
|
161960
|
162004
|
162005
|
162006
|
162007
|
162008
|
162009
|
162010
|
162011
|
162527
|
162528
|
162692
|
162693
|
162694
|
163527
|
164586
|
164590
|
164602
|
164603
|
164604
|
164605
|
164606
|
164618
|
164619
|
164620
|
164621
|
164622
|
165199
|
165594
|
165595
|
165596
|
165597
|
165598
|
167106
|
167107
|
167171
|
167172
|
167173
|
167174
|
167175
|
167176
|
168982
|
168983
|
169941
|
171255
|
171258
|
171260
|
171264
|
171265
|
171267
|
171675
|
171676
|
171678
|
171679
|
172072
|
172073
|
172074
|
172075
|
172076
|
172077
|
172078
|
172079
|
172080
|
172081
|
172082
|
172083
|
172202
|
172203
|
172204
|
172205
|
172206
|
172207
|
172208
|
172209
|
172210
|
172211
|
172212
|
172213
|
173088
| 173089 |
173090
|
173091
|
173092
|
173093
|
173094
|
173095
|
173096
|
173097
|
173098
|
173099
|
173100
|
173101
|
173561
|
173599
|
173600
|
173601
|
173614
|
174790