Bug 32741 - Attribute codes should not be repeated in bib1.att
Summary: Attribute codes should not be repeated in bib1.att
Status: RESOLVED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Searching - Zebra (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal
Assignee: Tomás Cohen Arazi (tcohen)
QA Contact:
URL:
Keywords:
Depends on: 32416
Blocks:
  Show dependency treegraph
 
Reported: 2023-01-27 19:04 UTC by Tomás Cohen Arazi (tcohen)
Modified: 2023-12-28 20:44 UTC (History)
8 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
23.05.00,22.11.03,22.05.10,21.11.16
Circulation function:


Attachments
Bug 32741: Regression tests (1.89 KB, patch)
2023-01-27 19:06 UTC, Tomás Cohen Arazi (tcohen)
Details | Diff | Splinter Review
Bug 32741: Fix {biblios|authorities}/bib1.att duplicate codes (1.87 KB, patch)
2023-01-27 19:39 UTC, Tomás Cohen Arazi (tcohen)
Details | Diff | Splinter Review
Bug 32741: Regression tests (1.94 KB, patch)
2023-01-27 20:48 UTC, David Nind
Details | Diff | Splinter Review
Bug 32741: Fix {biblios|authorities}/bib1.att duplicate codes (1.91 KB, patch)
2023-01-27 20:48 UTC, David Nind
Details | Diff | Splinter Review
Bug 32741: Regression tests (2.00 KB, patch)
2023-02-01 13:10 UTC, Martin Renvoize (ashimema)
Details | Diff | Splinter Review
Bug 32741: Fix {biblios|authorities}/bib1.att duplicate codes (1.98 KB, patch)
2023-02-01 13:11 UTC, Martin Renvoize (ashimema)
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Tomás Cohen Arazi (tcohen) 2023-01-27 19:04:26 UTC
Raised on bug 32416, we should prevent this to happen.
Comment 1 Tomás Cohen Arazi (tcohen) 2023-01-27 19:06:00 UTC
Created attachment 145770 [details] [review]
Bug 32741: Regression tests

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 2 Tomás Cohen Arazi (tcohen) 2023-01-27 19:39:02 UTC
Created attachment 145773 [details] [review]
Bug 32741: Fix {biblios|authorities}/bib1.att duplicate codes

This patch fixes a duplicate attribute code for Author-in-order in the
biblios definition.
The picked code matches what was already in ccl.properties.

Also Chronological-term for authorities gets fixed.

To test:
1. Apply the regression tests
2. Run:
  k$ prove xt/verify_bib1.att.t
=> FAIL: Some failiures
3. Apply this patch
4. Repeat 1
=> SUCCESS: Tests now pass!
5. Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 3 David Nind 2023-01-27 20:19:45 UTC
Tests still fail for me after applying the fix patch 8-(..

prove xt/verify_bib1.att.t
xt/verify_bib1.att.t .. 
    #   Failed test 'Only one occurrence for code (9014)'
    #   at xt/verify_bib1.att.t line 42.
    #          got: '2'
    #     expected: '1'
    # Looks like you failed 1 test of 289.
xt/verify_bib1.att.t .. 1/2 
#   Failed test 'bib1.att tests for biblios'
#   at xt/verify_bib1.att.t line 44.
# Looks like you failed 1 test of 2.
xt/verify_bib1.att.t .. Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/2 subtests 

Test Summary Report
-------------------
xt/verify_bib1.att.t (Wstat: 256 Tests: 2 Failed: 1)
  Failed test:  1
  Non-zero exit status: 1
Files=1, Tests=2,  0 wallclock secs ( 0.03 usr  0.00 sys +  0.12 cusr  0.02 csys =  0.17 CPU)
Result: FAIL
Comment 4 Tomás Cohen Arazi (tcohen) 2023-01-27 20:36:42 UTC
(In reply to David Nind from comment #3)
> Tests still fail for me after applying the fix patch 8-(..

You applied it on an outdated branch? Bug 32416 fixes that case, and I'm sure I pushed to master.
Comment 5 David Nind 2023-01-27 20:47:39 UTC
(In reply to Tomás Cohen Arazi from comment #4)
> (In reply to David Nind from comment #3)
> > Tests still fail for me after applying the fix patch 8-(..
> 
> You applied it on an outdated branch? Bug 32416 fixes that case, and I'm
> sure I pushed to master.

You are absolutely right! (I only updated master about an hour or so ago 8)). Everything now passes with an up-to-date master. 

Sign off on the way....
Comment 6 David Nind 2023-01-27 20:48:39 UTC
Created attachment 145777 [details] [review]
Bug 32741: Regression tests

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: David Nind <david@davidnind.com>
Comment 7 David Nind 2023-01-27 20:48:44 UTC
Created attachment 145778 [details] [review]
Bug 32741: Fix {biblios|authorities}/bib1.att duplicate codes

This patch fixes a duplicate attribute code for Author-in-order in the
biblios definition.
The picked code matches what was already in ccl.properties.

Also Chronological-term for authorities gets fixed.

To test:
1. Apply the regression tests
2. Run:
  k$ prove xt/verify_bib1.att.t
=> FAIL: Some failiures
3. Apply this patch
4. Repeat 1
=> SUCCESS: Tests now pass!
5. Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: David Nind <david@davidnind.com>
Comment 8 Martin Renvoize (ashimema) 2023-02-01 13:10:59 UTC
Created attachment 145936 [details] [review]
Bug 32741: Regression tests

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 9 Martin Renvoize (ashimema) 2023-02-01 13:11:05 UTC
Created attachment 145937 [details] [review]
Bug 32741: Fix {biblios|authorities}/bib1.att duplicate codes

This patch fixes a duplicate attribute code for Author-in-order in the
biblios definition.
The picked code matches what was already in ccl.properties.

Also Chronological-term for authorities gets fixed.

To test:
1. Apply the regression tests
2. Run:
  k$ prove xt/verify_bib1.att.t
=> FAIL: Some failiures
3. Apply this patch
4. Repeat 1
=> SUCCESS: Tests now pass!
5. Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 10 Martin Renvoize (ashimema) 2023-02-01 13:11:43 UTC
Nice to have regressions tests here now, all works as expected, no regressions.

Passing QA
Comment 11 Tomás Cohen Arazi (tcohen) 2023-02-02 15:02:16 UTC
Pushed to master for 23.05.

Nice work everyone, thanks!
Comment 12 Jacob O'Mara 2023-02-06 15:58:41 UTC
Nice work, thanks everyone!

Pushed to 22.11.x for the next release.
Comment 13 Lucas Gass (lukeg) 2023-02-14 21:47:55 UTC
Backported to 22.05.x for upcoming 22.05.10
Comment 14 Arthur Suzuki 2023-02-17 10:08:06 UTC
applied to 21.11.x for 21.11.16
Comment 15 Wainui Witika-Park 2023-03-15 01:44:21 UTC
Not backported to 21.05.x