Bug 25807 - Version 3.008 of Template breaks smart-rules display
Summary: Version 3.008 of Template breaks smart-rules display
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Circulation (show other bugs)
Version: Main
Hardware: All All
: P5 - low minor
Assignee: Martin Renvoize (ashimema)
QA Contact: Testopia
URL: https://github.com/abw/Template2/issu...
Keywords:
Depends on:
Blocks:
 
Reported: 2020-06-18 15:25 UTC by Martin Renvoize (ashimema)
Modified: 2021-12-13 21:08 UTC (History)
7 users (show)

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


Attachments
Bug 25807: Add Template 3.008 to the exclude list (2.49 KB, patch)
2020-06-24 10:36 UTC, Martin Renvoize (ashimema)
Details | Diff | Splinter Review
Bug 25807: Add Template 3.008 to the exclude list (2.55 KB, patch)
2020-06-24 11:10 UTC, Tomás Cohen Arazi (tcohen)
Details | Diff | Splinter Review
Bug 25807: Add Template 3.008 to the exclude list (2.60 KB, patch)
2020-06-26 10:10 UTC, Julian Maurice
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Renvoize (ashimema) 2020-06-18 15:25:14 UTC
I just did a trial upgrade of a site and it resulted in 2769 rules in the circulation_rules table.. many of them duplicates and generally a corrupt set of data. (We had 246 circulation_rules and just 87 issuingrules prior to the upgrade being run).

It appears to be an error in the update query of bug 18936
Comment 1 Martin Renvoize (ashimema) 2020-06-18 16:23:16 UTC
Hmm.. the table looks right.. but the display is wrong...

Investigating further.
Comment 2 Martin Renvoize (ashimema) 2020-06-19 14:38:04 UTC
Reducing priority because although I can replicate it regularly, with the exact same dataset Jonathan cannot.

I believe it's something to do with DB version but as yet haven't managed to narrow it down further.
Comment 3 Martin Renvoize (ashimema) 2020-06-24 10:08:54 UTC
Right.. this isn't data related at all.. it's Module version related.

I have been running my dev environment with the latest dependencies from CPAN.. it seems Template 3.008 broke support for the [% SET variable UNLESS condition %] syntax which we are using in the smart rules template.

See https://github.com/abw/Template2/issues/263 for the bug report upstream
Comment 4 Martin Renvoize (ashimema) 2020-06-24 10:36:06 UTC
Created attachment 106241 [details] [review]
Bug 25807: Add Template 3.008 to the exclude list

This patch adds version 3.008 of Template to the excludes list in our
cpanfile. It also adds support for displaying this version on the about
page.
Comment 5 Martin Renvoize (ashimema) 2020-06-24 10:41:23 UTC
Test plan
1/ Ensure you have a version of Template installed that is supported (i.e >= 2.22 but not 3.008)
2/ Look at the about page and note `2.22, !3.008` is displayed for the 'Template' module in 'grey'
3/ Update your version of Template to 3.008 (cpanm Template@3.008)
4/ Refresh the about screen and note that 'Template' now displays in 'yellow'
5/ Signoff
6/ Revert your version of Template (so you can work properly again, cpanm Template@2.22)
Comment 6 Tomás Cohen Arazi (tcohen) 2020-06-24 11:10:40 UTC
Created attachment 106242 [details] [review]
Bug 25807: Add Template 3.008 to the exclude list

This patch adds version 3.008 of Template to the excludes list in our
cpanfile. It also adds support for displaying this version on the about
page.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 7 Julian Maurice 2020-06-26 10:10:46 UTC
Created attachment 106325 [details] [review]
Bug 25807: Add Template 3.008 to the exclude list

This patch adds version 3.008 of Template to the excludes list in our
cpanfile. It also adds support for displaying this version on the about
page.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Comment 8 Jonathan Druart 2020-06-29 11:50:49 UTC
Pushed to master for 20.11, thanks to everybody involved!
Comment 9 Lucas Gass (lukeg) 2020-07-13 16:05:37 UTC
backported to 20.05.x for 20.05.02
Comment 10 Aleisha Amohia 2020-07-16 04:29:57 UTC
Hey all, this does not apply cleanly on 19.11.x, please rebase if you'd like me to backport.