Bug 30534 - borrowers.guarantorid not present on database
Summary: borrowers.guarantorid not present on database
Status: RESOLVED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: REST API (show other bugs)
Version: unspecified
Hardware: All All
: P5 - low normal (vote)
Assignee: Tomás Cohen Arazi
QA Contact:
URL:
Keywords:
: 27077 (view as bug list)
Depends on: 14570
Blocks:
  Show dependency treegraph
 
Reported: 2022-04-13 19:31 UTC by Tomás Cohen Arazi
Modified: 2022-06-17 03:09 UTC (History)
7 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:
22.05.00,21.11.06


Attachments
Bug 30534: Remove guarantor_id attribute from the patron object (1.67 KB, patch)
2022-04-13 20:09 UTC, Tomás Cohen Arazi
Details | Diff | Splinter Review
Bug 30534: Remove guarantor_id attribute from the patron object (1.72 KB, patch)
2022-04-19 10:50 UTC, David Nind
Details | Diff | Splinter Review
Bug 30534: Remove guarantor_id attribute from the patron object (1.80 KB, patch)
2022-04-21 09:27 UTC, Jonathan Druart
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 2022-04-13 19:31:13 UTC
The column was removed on bug 14570 (19.11) but the API mapping was inadvertedly kept.

We should remove it.

To test:
- Try to filter a request by that attribute:

http://kohadev-intra.myDNSname.org:8081/api/v1/patrons?guarantor_id=1
http://kohadev-intra.myDNSname.org:8081/api/v1/patrons?q={"guarantor_id"=1}

=> FAIL: You get a 500
Comment 1 Tomás Cohen Arazi 2022-04-13 20:09:22 UTC
Created attachment 133282 [details] [review]
Bug 30534: Remove guarantor_id attribute from the patron object

This patch removes an attribute that was actually removed 3 years ago
and causes an exception when trying to search for it. The API responses
don't include it anyways.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 2 David Nind 2022-04-19 10:50:11 UTC
Created attachment 133398 [details] [review]
Bug 30534: Remove guarantor_id attribute from the patron object

This patch removes an attribute that was actually removed 3 years ago
and causes an exception when trying to search for it. The API responses
don't include it anyways.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Signed-off-by: David Nind <david@davidnind.com>
Comment 3 Jonathan Druart 2022-04-21 09:27:36 UTC
Created attachment 133530 [details] [review]
Bug 30534: Remove guarantor_id attribute from the patron object

This patch removes an attribute that was actually removed 3 years ago
and causes an exception when trying to search for it. The API responses
don't include it anyways.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 4 Jonathan Druart 2022-04-21 09:28:27 UTC
There are more occurrences that haven't been removed, see bug 14570 comment 251
Comment 5 Katrin Fischer 2022-04-21 22:43:17 UTC
The bug description makes it sound a bit like the column should be in the database, but I think this is about removing some left-over code, right?
Comment 6 Fridolin Somers 2022-04-25 20:02:03 UTC
Pushed to master for 22.05, thanks to everybody involved 🦄
Comment 7 Tomás Cohen Arazi 2022-04-28 11:41:06 UTC
*** Bug 27077 has been marked as a duplicate of this bug. ***
Comment 8 Kyle M Hall 2022-05-06 14:58:50 UTC
Pushed to 21.11.x for 21.11.06
Comment 9 Victor Grousset/tuxayo 2022-06-17 03:09:16 UTC
Not backported to oldoldstable (21.05.x). Feel free to ask if it's needed.