Bug 38271 - Missing 008 field in bibliographic records created via EDIFACT
Summary: Missing 008 field in bibliographic records created via EDIFACT
Status: RESOLVED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Acquisitions (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal
Assignee: Matt Blenkinsop
QA Contact: Kyle M Hall (khall)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-10-25 11:18 UTC by Matt Blenkinsop
Modified: 2025-02-03 16:46 UTC (History)
6 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
24.11.00,24.05.06,23.11.11
Circulation function:


Attachments
Bug 38271: Handle missing 008 fields in EDI (8.37 KB, patch)
2024-10-25 11:20 UTC, Matt Blenkinsop
Details | Diff | Splinter Review
Bug 38271: Handle missing 008 fields in EDI (8.42 KB, patch)
2024-10-25 13:07 UTC, Kyle M Hall (khall)
Details | Diff | Splinter Review
Bug 38271: (QA follow-up) Tidy code (2.45 KB, patch)
2024-10-25 13:08 UTC, Kyle M Hall (khall)
Details | Diff | Splinter Review
Bug 38271: (QA follow-up) Fix testcritic (856 bytes, patch)
2024-10-28 09:36 UTC, Matt Blenkinsop
Details | Diff | Splinter Review
Bug 38271: (QA follow-up) Fix testcritic (854 bytes, patch)
2024-10-28 10:27 UTC, Matt Blenkinsop
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Matt Blenkinsop 2024-10-25 11:18:54 UTC
Bib records created through the EDI process don't always include the 008 field which can cause breakages when connected to discovery systems that require it. We need to set a default field on those records as it is a mandatory MARC field
Comment 1 Matt Blenkinsop 2024-10-25 11:20:51 UTC
Created attachment 173347 [details] [review]
Bug 38271: Handle missing 008 fields in EDI

This patch adds handling to create a default 008 field on MARC records that are missing one when created through EDI.

Test plan:
1) prove t/db_dependent/Koha/EDI.t
Comment 2 Kyle M Hall (khall) 2024-10-25 13:07:50 UTC
Created attachment 173357 [details] [review]
Bug 38271: Handle missing 008 fields in EDI

This patch adds handling to create a default 008 field on MARC records that are missing one when created through EDI.

Test plan:
1) prove t/db_dependent/Koha/EDI.t

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Comment 3 Kyle M Hall (khall) 2024-10-25 13:08:09 UTC
Created attachment 173358 [details] [review]
Bug 38271: (QA follow-up) Tidy code

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Comment 4 Martin Renvoize (ashimema) 2024-10-28 08:29:56 UTC
Upgrading Kyle's SO to a QA.. I'm happy with the code and there's very very few of us our here who understand EDI well enough to QA.
Comment 5 Matt Blenkinsop 2024-10-28 09:36:07 UTC
Created attachment 173442 [details] [review]
Bug 38271: (QA follow-up) Fix testcritic

testcritic was failing due to a 'return undef' so this commit amends that

Test plan:
1) prove t/00-testcritic.t
Comment 6 Matt Blenkinsop 2024-10-28 10:27:19 UTC
Created attachment 173490 [details] [review]
Bug 38271: (QA follow-up) Fix testcritic

testcritic was failing due to a 'return undef' so this commit amends that

Test plan:
1) prove t/00-testcritic.t
Comment 7 Katrin Fischer 2024-10-28 18:20:05 UTC
Happy to see unit tests!
Comment 8 Katrin Fischer 2024-10-29 07:54:46 UTC
Pushed for 24.11!

Well done everyone, thank you!
Comment 9 Lucas Gass (lukeg) 2024-11-22 21:36:13 UTC
Backported to 24.05.x for upcoming 24.05.06
Comment 10 Fridolin Somers 2024-12-13 15:31:40 UTC
Pushed to 23.11.x for 23.11.11
Comment 11 Jesse Maseto 2025-02-03 16:46:43 UTC
Not pushed to LTS. Marked Resolved.

If you feel this should be in LTS please reply with your reason.