Bug 33297

Summary: Typo system preference RetainPatronSearchTerms in DB revs 220600044.pl
Product: Koha Reporter: Fridolin Somers <fridolin.somers>
Component: SearchingAssignee: Fridolin Somers <fridolin.somers>
Status: RESOLVED FIXED QA Contact: Marcel de Rooy <m.de.rooy>
Severity: major    
Priority: P5 - low CC: david, dcook, didier.gautheron, jonathan.druart, m.de.rooy, tomascohen
Version: Main   
Hardware: All   
OS: All   
See Also: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33300
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.07
Bug Depends on: 26247    
Bug Blocks:    
Attachments: Bug 33297: Fix typo system preference RetainPatronSearchTerms in DB revs 220600044.pl
Bug 33297: (follow-up) DBRev for existing databases
Bug 33297: Fix typo system preference RetainPatronSearchTerms in DB revs 220600044.pl
Bug 33297: (follow-up) DBRev for existing databases
Bug 33297: (follow-up) DBRev check wrong preference exists
Bug 33297: Fix typo system preference RetainPatronSearchTerms in DB revs 220600044.pl
Bug 33297: (follow-up) DBRev for existing databases
Bug 33297: (follow-up) DBRev check wrong preference exists

Description Fridolin Somers 2023-03-22 08:01:40 UTC
Bug 26247 added system preference RetainPatronsSearchTerms.
There is a typo in DB revs 220600044.pl : RetainPatronSearchTerms instead of RetainPatronsSearchTerms.
Comment 1 Fridolin Somers 2023-03-22 08:06:37 UTC
Created attachment 148503 [details] [review]
Bug 33297: Fix typo system preference RetainPatronSearchTerms in DB revs 220600044.pl

Bug 26247 added system preference RetainPatronsSearchTerms.
There is a typo in DB revs 220600044.pl : RetainPatronSearchTerms instead of RetainPatronsSearchTerms.

Test plan :
Upgrade from 22.05 to 22.11 and check there is a system preference named 'RetainPatronsSearchTerms'
Comment 2 Fridolin Somers 2023-03-22 08:12:52 UTC
Tell me if we should also fix already updated databases ?
Comment 3 Fridolin Somers 2023-03-22 08:13:45 UTC
> (22:11:30) Joubu: fridolin: then you need a new db revs for those who upgraded already
Comment 4 Fridolin Somers 2023-03-22 08:35:31 UTC
Created attachment 148504 [details] [review]
Bug 33297: (follow-up) DBRev for existing databases

Test plan :
1.1) Start from a Koha 22.05
1.2) Upgrade to master
=> Check the upgrade says :
   Wrong system preference 'RetainPatronSearchTerms' renamed 'RetainPatronsSearchTerms'
2.1) Start from a Koha 22.05
2.2) Upgrade to 22.11
2.3) Via interface change system preference 'RetainPatronsSearchTerms' and save
2.4) Upgrade to master
=> Check the upgrade says :
   Wrong system preference 'RetainPatronSearchTerms' deleted
Comment 5 Didier Gautheron 2023-03-22 08:49:23 UTC
*** Bug 33291 has been marked as a duplicate of this bug. ***
Comment 6 Marcel de Rooy 2023-03-23 06:43:22 UTC
Created attachment 148582 [details] [review]
Bug 33297: Fix typo system preference RetainPatronSearchTerms in DB revs 220600044.pl

Bug 26247 added system preference RetainPatronsSearchTerms.
There is a typo in DB revs 220600044.pl : RetainPatronSearchTerms instead of RetainPatronsSearchTerms.

Test plan :
Upgrade from 22.05 to 22.11 and check there is a system preference named 'RetainPatronsSearchTerms'

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 7 Marcel de Rooy 2023-03-23 06:43:24 UTC
Created attachment 148583 [details] [review]
Bug 33297: (follow-up) DBRev for existing databases

Test plan :
1.1) Start from a Koha 22.05
1.2) Upgrade to master
=> Check the upgrade says :
   Wrong system preference 'RetainPatronSearchTerms' renamed 'RetainPatronsSearchTerms'
2.1) Start from a Koha 22.05
2.2) Upgrade to 22.11
2.3) Via interface change system preference 'RetainPatronsSearchTerms' and save
2.4) Upgrade to master
=> Check the upgrade says :
   Wrong system preference 'RetainPatronSearchTerms' deleted

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 8 Marcel de Rooy 2023-03-23 06:43:55 UTC
trivial, SO+QA in one step
Comment 9 Marcel de Rooy 2023-03-23 06:44:32 UTC
No blocker, but the dbrev says 'deleted' even when it did not delete (since there was none)..
Comment 10 Fridolin Somers 2023-03-23 07:10:22 UTC
Created attachment 148584 [details] [review]
Bug 33297: (follow-up) DBRev check wrong preference exists

Better db upgrade messages
Comment 11 Fridolin Somers 2023-03-23 07:11:28 UTC
(In reply to Marcel de Rooy from comment #9)
> No blocker, but the dbrev says 'deleted' even when it did not delete (since
> there was none)..

Oh indeed, follow-up added.
Comment 12 David Cook 2023-03-30 06:01:12 UTC
Hoping to look at these soon...
Comment 13 Jonathan Druart 2023-05-04 10:30:17 UTC
(In reply to David Cook from comment #12)
> Hoping to look at these soon...

How soon?
Comment 14 David Cook 2023-05-04 23:19:58 UTC
(In reply to Jonathan Druart from comment #13)
> (In reply to David Cook from comment #12)
> > Hoping to look at these soon...
> 
> How soon?

Alas, I've given up hope for now.
Comment 15 David Nind 2023-05-06 23:17:25 UTC
I'd like to test, but don't know how to do step 1.2 (upgrading from 22.05 to master) using KTD (koha-testing-docker).

If I could get some instructions on how to do that, I'll happily test.
Comment 16 Jonathan Druart 2023-05-16 13:47:06 UTC
Created attachment 151280 [details] [review]
Bug 33297: Fix typo system preference RetainPatronSearchTerms in DB revs 220600044.pl

Bug 26247 added system preference RetainPatronsSearchTerms.
There is a typo in DB revs 220600044.pl : RetainPatronSearchTerms instead of RetainPatronsSearchTerms.

Test plan :
Upgrade from 22.05 to 22.11 and check there is a system preference named 'RetainPatronsSearchTerms'

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 17 Jonathan Druart 2023-05-16 13:47:09 UTC
Created attachment 151281 [details] [review]
Bug 33297: (follow-up) DBRev for existing databases

Test plan :
1.1) Start from a Koha 22.05
1.2) Upgrade to master
=> Check the upgrade says :
   Wrong system preference 'RetainPatronSearchTerms' renamed 'RetainPatronsSearchTerms'
2.1) Start from a Koha 22.05
2.2) Upgrade to 22.11
2.3) Via interface change system preference 'RetainPatronsSearchTerms' and save
2.4) Upgrade to master
=> Check the upgrade says :
   Wrong system preference 'RetainPatronSearchTerms' deleted

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 18 Jonathan Druart 2023-05-16 13:47:12 UTC
Created attachment 151282 [details] [review]
Bug 33297: (follow-up) DBRev check wrong preference exists

Better db upgrade messages

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 19 Jonathan Druart 2023-05-16 13:47:25 UTC
(In reply to David Nind from comment #15)
> I'd like to test, but don't know how to do step 1.2 (upgrading from 22.05 to
> master) using KTD (koha-testing-docker).
> 
> If I could get some instructions on how to do that, I'll happily test.

% git checkout v22.05.00

% reset_all

% git checkout master

> SELECT variable from systempreferences where variable like "%RetainPatron%";
Comment 20 Jonathan Druart 2023-05-16 13:48:09 UTC
I am not sure about "Wrong system preference 'RetainPatronSearchTerms' does not exist"

I would say: If nothing is wrong, then tell nothing. It could be confusing.
Comment 21 Tomás Cohen Arazi 2023-05-16 17:22:55 UTC
(In reply to Jonathan Druart from comment #20)
> I am not sure about "Wrong system preference 'RetainPatronSearchTerms' does
> not exist"
> 
> I would say: If nothing is wrong, then tell nothing. It could be confusing.

Agreed.
Comment 22 Tomás Cohen Arazi 2023-05-16 18:19:26 UTC
Pushed to master for 23.05.

Nice work everyone, thanks!
Comment 23 Pedro Amorim 2023-06-07 12:18:46 UTC
Nice work everyone!

Pushed to 22.11.x for next release