[Bug 19315] New: Routing preview may use wrong biblionumber
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 Bug ID: 19315 Summary: Routing preview may use wrong biblionumber Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Serials Assignee: koha-bugs@lists.koha-community.org Reporter: nick@bywatersolutions.com QA Contact: testopia@bugs.koha-community.org CC: colin.campbell@ptfs-europe.com When generating the routing preview from the serials collection screen: /cgi-bin/koha/serials/serials-collection.pl?subscriptionid=## the subscription information is obtained via a mysql call in C4::Serials::GetSubscription, however, the statement pulls subscription.* and subscriptionhistory.* Both of these have a biblionumber field, so when routing-preview.pl pulls the biblionumber it may get bad information -- 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=19315 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff Patch complexity|--- |Trivial patch -- 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=19315 --- Comment #1 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 67134 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=67134&action=edit Bug 19315 - Use bibnum instead of biblionumber in routing-preview.pl and add item check To test: 1 - Create a serial subscription attached to a record 2 - Receive some issues 3 - Edit the subscription 4 - Go to serails collection 5 - Try to print a routing list 6 - You may or may not get the right serial 7 - Additionally create a subscription attached to a bib with no items 8 - Try to print a routing list for this serial 9 - You will get 'Internal server error' 10 - Apply patch 11 - Print routing list for first serial 12 - You will always get the correct bib 13 - Print routing list for second serial 14 - You should no longer get an error -- 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=19315 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |nick@bywatersolutions.com |ity.org | Severity|enhancement |normal -- 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=19315 Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |caroline.cyr-la-rose@inlibr | |o.com --- Comment #2 from Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> --- At step 5, I'm getting the error message : "Can't call method "branchname" on an undefined value at /inlibro/git/koha-master-dev-inlibro/serials/routing-preview.pl line 72." Is it something I'm doing wrong? I didn't apply the patch yet. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off --- Comment #3 from Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> --- At step 9, I get a software error :"Can't call method "store" on an undefined value at /inlibro/git/koha-master-dev-inlibro/C4/Reserves.pm line 907." After applying the patch, everything/both routing lists works! yay! It's hard to know if I would've gotten the right info on the first routing list (steps 1-6) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #67134|0 |1 is obsolete| | --- Comment #4 from Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> --- Created attachment 67164 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=67164&action=edit Bug 19315 - Use bibnum instead of biblionumber in routing-preview.pl and add item check To test: 1 - Create a serial subscription attached to a record 2 - Receive some issues 3 - Edit the subscription 4 - Go to serails collection 5 - Try to print a routing list 6 - You may or may not get the right serial 7 - Additionally create a subscription attached to a bib with no items 8 - Try to print a routing list for this serial 9 - You will get 'Internal server error' 10 - Apply patch 11 - Print routing list for first serial 12 - You will always get the correct bib 13 - Print routing list for second serial 14 - You should no longer get an error Signed-off-by: Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #67164|0 |1 is obsolete| | --- Comment #5 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 67668 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=67668&action=edit Bug 19315 - Use bibnum instead of biblionumber in routing-preview.pl and add item check To test: 1 - Create a serial subscription attached to a record 2 - Receive some issues 3 - Edit the subscription 4 - Go to serails collection 5 - Try to print a routing list 6 - You may or may not get the right serial 7 - Additionally create a subscription attached to a bib with no items 8 - Try to print a routing list for this serial 9 - You will get 'Internal server error' 10 - Apply patch 11 - Print routing list for first serial 12 - You will always get the correct bib 13 - Print routing list for second serial 14 - You should no longer get an error Signed-off-by: Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 --- Comment #6 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 67669 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=67669&action=edit Bug 19315: [QA Follow-up] Trivial edits Replace $subs->{bibnum} by $biblionumber on a following line. The scalar in the boolean expression is not needed. Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact|testopia@bugs.koha-communit |m.de.rooy@rijksmuseum.nl |y.org | CC| |m.de.rooy@rijksmuseum.nl --- Comment #7 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Nick: Isnt there anything to be done on the GetSubscription output? Whats the use of the 'wrong' biblionumber ? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 --- Comment #8 from Nick Clemens <nick@bywatersolutions.com> --- (In reply to Marcel de Rooy from comment #7)
Nick: Isnt there anything to be done on the GetSubscription output? Whats the use of the 'wrong' biblionumber ?
Technically yes, the 'wrong' biblionumber can't reliably be used for anything, it's more convenience as you can't get 'all columns but one' Right now we have: SELECT subscription.*, subscriptionhistory.*, And to fix we would have to list every field individually: SELECT subscription.subscriptionid,subscription.biblionumber AS sbiblionumber,librarian, startdate... subscriptionhistory.biblionumber AS shbiblionumber,histstartdatem histenddate,missinglist... -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to Master --- Comment #9 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Pushed to master for 17.11, thanks to everybody involved! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 Fridolin SOMERS <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |fridolin.somers@biblibre.co | |m --- Comment #10 from Fridolin SOMERS <fridolin.somers@biblibre.com> --- I test for 17.05.x : With patches applied. I have create a subscription without branch nor items. Printing a routing list for this serial returns an error : Can't call method "branchname" on an undefined value at /home/koha/src/serials/routing-preview.pl line 71. Maybe $branch should be tested : - my $branchname = Koha::Libraries->find($branch)->branchname; + my $branchname = Koha::Libraries->find($branch)->branchname if $branch; -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |katrin.fischer@bsz-bw.de --- Comment #11 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Patches don't apply cleanly on 16.11.x, please rebase if you want this to be included. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 --- Comment #12 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 70022 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=70022&action=edit Bug 19315: Prevent crash if no items and not library set for the subscription Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jonathan.druart@bugs.koha-c | |ommunity.org --- Comment #13 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (In reply to Jonathan Druart from comment #12)
Created attachment 70022 [details] [review] Bug 19315: Prevent crash if no items and not library set for the subscription
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This patch has been pushed to master for 18.05 The first 2 patches have been pushed already to 17.11 and 17.05, this one must be pushed as well. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 --- Comment #14 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 70026 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=70026&action=edit Bug 19315: [16.11.x] Use bibnum instead of biblionumber in routing-preview.pl and add item check To test: 1 - Create a serial subscription attached to a record 2 - Receive some issues 3 - Edit the subscription 4 - Go to serails collection 5 - Try to print a routing list 6 - You may or may not get the right serial 7 - Additionally create a subscription attached to a bib with no items 8 - Try to print a routing list for this serial 9 - You will get 'Internal server error' 10 - Apply patch 11 - Print routing list for first serial 12 - You will always get the correct bib 13 - Print routing list for second serial 14 - You should no longer get an error Signed-off-by: Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 --- Comment #15 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 70027 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=70027&action=edit Bug 19315: [16.11.x] [QA Follow-up] Trivial edits Replace $subs->{bibnum} by $biblionumber on a following line. The scalar in the boolean expression is not needed. Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 --- Comment #16 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 70028 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=70028&action=edit Bug 19315: [16.11.x] Prevent crash if no items and not library set for the subscription Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 --- Comment #17 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- And the last 3 patches are the 16.11.x version -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 --- Comment #18 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- *** Bug 19858 has been marked as a duplicate of this bug. *** -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #70026|0 |1 is obsolete| | Attachment #70027|0 |1 is obsolete| | Attachment #70028|0 |1 is obsolete| | --- Comment #19 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Created attachment 70044 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=70044&action=edit [SIGNED-OFF] Bug 19315: [16.11.x] Use bibnum instead of biblionumber in routing-preview.pl and add item check To test: 1 - Create a serial subscription attached to a record 2 - Receive some issues 3 - Edit the subscription 4 - Go to serails collection 5 - Try to print a routing list 6 - You may or may not get the right serial 7 - Additionally create a subscription attached to a bib with no items 8 - Try to print a routing list for this serial 9 - You will get 'Internal server error' 10 - Apply patch 11 - Print routing list for first serial 12 - You will always get the correct bib 13 - Print routing list for second serial 14 - You should no longer get an error Signed-off-by: Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 --- Comment #20 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Created attachment 70045 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=70045&action=edit [SIGNED-OFF] Bug 19315: [16.11.x] [QA Follow-up] Trivial edits Replace $subs->{bibnum} by $biblionumber on a following line. The scalar in the boolean expression is not needed. Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 --- Comment #21 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Created attachment 70046 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=70046&action=edit [SIGNED-OFF] Bug 19315: [16.11.x] Prevent crash if no items and not library set for the subscription Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19315 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to Master |Pushed to Stable --- Comment #22 from Nick Clemens <nick@bywatersolutions.com> --- Patch in comment 12 has been pushed to stable for 17.11.01 -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org