[Bug 37032] New: REST API: Unable to call item info via holds endpoint
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 Bug ID: 37032 Summary: REST API: Unable to call item info via holds endpoint Change sponsored?: --- Product: Koha Version: Main Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: REST API Assignee: koha-bugs@lists.koha-community.org Reporter: emmi.takkinen@koha-suomi.fi CC: tomascohen@gmail.com I'm trying to fetch items barcode via holds endpoint with no luck. If I've understood correctly, this should be possible by adding item as embed in /api/v1/swagger/paths/holds.yaml and then adding it to enum option in kohaTable function. However this only leads to following error:
Something went wrong when loading the table. 400: Bad Request. Not in enum list: cancellation_requested, biblio, pickup_library, item. Documentation for endpoint shows that endpoint should produce item object and Koha::Hold does have relation to item.
-- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 Emmi Takkinen <emmi.takkinen@koha-suomi.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |36135 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36135 [Bug 36135] Add tool to batch modify holds -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 --- Comment #1 from Emmi Takkinen <emmi.takkinen@koha-suomi.fi> --- It seems there is a typo in holds.yaml. Setting "collectionFormat: csv" is included inside "items" of "x-koha-embed". Fixing this allows me to add and call item as emded. However now some of my API calls fail on 500 error and Mojolicious compalains that "Not a HASH reference at /usr/share/perl5/SQL/Abstract/Classic.pm line 804". -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 --- Comment #2 from Emmi Takkinen <emmi.takkinen@koha-suomi.fi> --- (In reply to Emmi Takkinen from comment #1)
It seems there is a typo in holds.yaml. Setting "collectionFormat: csv" is included inside "items" of "x-koha-embed". Fixing this allows me to add and call item as emded. However now some of my API calls fail on 500 error and Mojolicious compalains that "Not a HASH reference at /usr/share/perl5/SQL/Abstract/Classic.pm line 804".
This doesn't seem to be related to emded problem. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 --- Comment #3 from Emmi Takkinen <emmi.takkinen@koha-suomi.fi> --- (In reply to Emmi Takkinen from comment #2)
(In reply to Emmi Takkinen from comment #1)
It seems there is a typo in holds.yaml. Setting "collectionFormat: csv" is included inside "items" of "x-koha-embed". Fixing this allows me to add and call item as emded. However now some of my API calls fail on 500 error and Mojolicious compalains that "Not a HASH reference at /usr/share/perl5/SQL/Abstract/Classic.pm line 804".
This doesn't seem to be related to emded problem.
I mean, fixing this doesn't lead to 500 errors. Those are rather related how I'm building my table with API result. Fixing that typo allows using embed objects again. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 Emmi Takkinen <emmi.takkinen@koha-suomi.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff Assignee|koha-bugs@lists.koha-commun |emmi.takkinen@koha-suomi.fi |ity.org | --- Comment #4 from Emmi Takkinen <emmi.takkinen@koha-suomi.fi> --- Created attachment 169266 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=169266&action=edit Bug 37032: Fix typo in holds.yaml There is a typo in holds.yaml which prevents fetching item as embeded object. Option "collectionFormat" should be under "x-koha-embed", not "items" array. To test prove t/db_dependent/api/v1/holds.t. Sponsored-by: Koha-Suomi Oy -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 --- Comment #5 from Emmi Takkinen <emmi.takkinen@koha-suomi.fi> --- I'm unsure what's proper testing method for this (other than running tests for holds.t). Please feel free to point out what else should be tested and I will adjust test plan accordingly. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 Emmi Takkinen <emmi.takkinen@koha-suomi.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- Severity|enhancement |normal --- Comment #6 from Emmi Takkinen <emmi.takkinen@koha-suomi.fi> --- Setting importance as normal since this prevents using endpoint with its full potential. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #169266|0 |1 is obsolete| | --- Comment #7 from David Nind <david@davidnind.com> --- Created attachment 170463 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=170463&action=edit Bug 37032: Fix typo in holds.yaml There is a typo in holds.yaml which prevents fetching item as embeded object. Option "collectionFormat" should be under "x-koha-embed", not "items" array. To test prove t/db_dependent/api/v1/holds.t. Sponsored-by: Koha-Suomi Oy Signed-off-by: David Nind <david@davidnind.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |martin.renvoize@ptfs-europe | |.com QA Contact| |martin.renvoize@ptfs-europe | |.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #170463|0 |1 is obsolete| | --- Comment #8 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 170532 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=170532&action=edit Bug 37032: Fix typo in holds.yaml There is a typo in holds.yaml which prevents fetching item as embeded object. Option "collectionFormat" should be under "x-koha-embed", not "items" array. To test prove t/db_dependent/api/v1/holds.t. Sponsored-by: Koha-Suomi Oy Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA --- Comment #9 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Ooops, thanks Emmi -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)| |24.11.00 released in| | Status|Passed QA |Pushed to main -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 --- Comment #10 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Pushed for 24.11! Well done everyone, thank you! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to main |Pushed to stable Version(s)|24.11.00 |24.11.00,24.05.06 released in| | CC| |lucas@bywatersolutions.com --- Comment #11 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- Backported to 24.05.x for upcoming 24.05.06 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to stable |Pushed to oldstable -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |fridolin.somers@biblibre.co | |m Status|Pushed to oldstable |Pushed to oldoldstable Version(s)|24.11.00,24.05.06 |24.11.00,24.05.06,23.11.11 released in| | --- Comment #12 from Fridolin Somers <fridolin.somers@biblibre.com> --- Pushed to 23.11.x for 23.11.11 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 Wainui Witika-Park <wainuiwitikapark@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to oldoldstable |Needs documenting CC| |wainuiwitikapark@catalyst.n | |et.nz --- Comment #13 from Wainui Witika-Park <wainuiwitikapark@catalyst.net.nz> --- Not backporting to 22.11 unless requested -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 Andrew Fuerste-Henry <andrew@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks|36135 | Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36135 [Bug 36135] Add tool to batch modify holds -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37032 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |david@davidnind.com Resolution|--- |FIXED Status|Needs documenting |RESOLVED --- Comment #14 from David Nind <david@davidnind.com> --- No changes to the manual required. -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org