[Bug 27166] New: SIP2 Connection is killed when an item that was not issued is checked in and generates a transfer
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27166 Bug ID: 27166 Summary: SIP2 Connection is killed when an item that was not issued is checked in and generates a transfer Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: major Priority: P5 - low Component: SIP2 Assignee: koha-bugs@lists.koha-community.org Reporter: nick@bywatersolutions.com QA Contact: testopia@bugs.koha-community.org CC: colin.campbell@ptfs-europe.com bug 21020 updated the SIP item with the destination branch by fetching it from the 'issue' object - if the item doesn't have an issue then the connection dies: problematic line in C4/SIP/ILS/Transaction/Checkin.pm: $self->{item}->destination_loc($issue->item->homebranch); To recreate: 1 - Have an item belonging to branch A 2 - Check it in via sip at branch B: perl misc/sip_cli_emulator.pl -a localhost -p 6001 -su term1 -sp term1 --item CHESS1 -l FPL -m checkin 3 - The read command is blank and there is a warn about uninitialized data -- 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=27166 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |21020 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21020 [Bug 21020] Return branch not set for transfer when using SIP -- 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=27166 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=27166 --- Comment #1 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 114257 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=114257&action=edit Bug 27166: Unit tests -- 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=27166 --- Comment #2 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 114258 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=114258&action=edit Bug 27166: Set destination_loc to item->homebranch In bug 21020 we used the issue to fetch the item and then the homebranch. This fails when the item is not issued. We fetch the item already, so we can use it directly To test: 1 - Have an item belonging to branch A 2 - Check it in via sip at branch B: perl misc/sip_cli_emulator.pl -a localhost -p 6001 -su term1 -sp term1 --item CHESS1 -l FPL -m checkin 3 - The read command is blank and there is a warn about uninitialized data 4 - Apply patch 5 - Restart sip server 6 - Check the item in at branch A using the sip cli emulator 7 - Check it in at branch B 8 - This time the checkin should succeed and the output msg should be included -- 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=27166 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jonathan.druart@bugs.koha-c | |ommunity.org, | |kyle@bywatersolutions.com, | |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=27166 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |nick@bywatersolutions.com |ity.org | -- 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=27166 Victor Grousset/tuxayo <victor@tuxayo.net> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #114257|0 |1 is obsolete| | --- Comment #3 from Victor Grousset/tuxayo <victor@tuxayo.net> --- Created attachment 114281 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=114281&action=edit Bug 27166: Unit tests Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27166 Victor Grousset/tuxayo <victor@tuxayo.net> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #114258|0 |1 is obsolete| | --- Comment #4 from Victor Grousset/tuxayo <victor@tuxayo.net> --- Created attachment 114282 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=114282&action=edit Bug 27166: Set destination_loc to item->homebranch In bug 21020 we used the issue to fetch the item and then the homebranch. This fails when the item is not issued. We fetch the item already, so we can use it directly To test: 1 - Have an item belonging to branch A 2 - Check it in via sip at branch B: perl misc/sip_cli_emulator.pl -a localhost -p 6001 -su term1 -sp term1 --item CHESS1 -l FPL -m checkin 3 - The read command is blank and there is a warn about uninitialized data 4 - Apply patch 5 - Restart sip server 6 - Check the item in at branch A using the sip cli emulator 7 - Check it in at branch B 8 - This time the checkin should succeed and the output msg should be included Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27166 Victor Grousset/tuxayo <victor@tuxayo.net> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off CC| |victor@tuxayo.net -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27166 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #114281|0 |1 is obsolete| | --- Comment #5 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 114301 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=114301&action=edit Bug 27166: Unit tests Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net> 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=27166 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #114282|0 |1 is obsolete| | --- Comment #6 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 114302 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=114302&action=edit Bug 27166: Set destination_loc to item->homebranch In bug 21020 we used the issue to fetch the item and then the homebranch. This fails when the item is not issued. We fetch the item already, so we can use it directly To test: 1 - Have an item belonging to branch A 2 - Check it in via sip at branch B: perl misc/sip_cli_emulator.pl -a localhost -p 6001 -su term1 -sp term1 --item CHESS1 -l FPL -m checkin 3 - The read command is blank and there is a warn about uninitialized data 4 - Apply patch 5 - Restart sip server 6 - Check the item in at branch A using the sip cli emulator 7 - Check it in at branch B 8 - This time the checkin should succeed and the output msg should be included Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net> 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=27166 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA --- Comment #7 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- This makes sense and also provides a minor performance boost (not double fetching the item). Tests pass, QA script passes... Passing QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27166 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact|testopia@bugs.koha-communit |martin.renvoize@ptfs-europe |y.org |.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27166 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=25726 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27166 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=27196 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27166 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)| |21.05.00 released in| | Status|Passed QA |Pushed to master -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27166 --- Comment #8 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Pushed to master for 21.05, 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=27166 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |fridolin.somers@biblibre.co | |m Version(s)|21.05.00 |21.05.00,20.11.01 released in| | Status|Pushed to master |Pushed to stable --- Comment #9 from Fridolin Somers <fridolin.somers@biblibre.com> --- Pushed to 20.11.x for 20.11.01 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27166 --- Comment #10 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 114536 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=114536&action=edit Bug 27166: [20.05.x] Set destination_loc to item->homebranch In bug 21020 we used the issue to fetch the item and then the homebranch. This fails when the item is not issued. We fetch the item already, so we can use it directly In 20.05.x we don't have the item object, so we can just use the SIP transaction item To test: 1 - Have an item belonging to branch A 2 - Check it in via sip at branch B: perl misc/sip_cli_emulator.pl -a localhost -p 6001 -su term1 -sp term1 --item CHESS1 -l FPL -m checkin 3 - The read command is blank and there is a warn about uninitialized data 4 - Apply patch 5 - Restart sip server 6 - Check the item in at branch A using the sip cli emulator 7 - Check it in at branch B 8 - This time the checkin should succeed and the output msg should be included Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net> 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=27166 Andrew Fuerste-Henry <andrew@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to stable |Pushed to oldstable CC| |andrew@bywatersolutions.com Version(s)|21.05.00,20.11.01 |21.05.00,20.11.01,20.05.07 released in| | --- Comment #11 from Andrew Fuerste-Henry <andrew@bywatersolutions.com> --- Pushed to 20.05.x for 20.05.07 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27166 --- Comment #12 from Victor Grousset/tuxayo <victor@tuxayo.net> --- The tests pass in 19.11.x but I have an error message not in 20.05.x kohadev-koha@9ddfdbbbd877:/kohadevbox/koha$ prove t/db_dependent/SIP/Transaction.t t/db_dependent/SIP/Transaction.t .. 7/10 AddReturn error: branch 'SIP2' not found. Reverting to bH8GNQ at /kohadevbox/koha/C4/Circulation.pm line 1844. AddReturn error: branch 'SIP2' not found. Reverting to bH8GNQ at /kohadevbox/koha/C4/Circulation.pm line 1844. t/db_dependent/SIP/Transaction.t .. 9/10 AddReturn error: branch 'SIP2' not found. Reverting to lw0u4bBY02 at /kohadevbox/koha/C4/Circulation.pm line 1844. AddReturn error: branch 'SIP2' not found. Reverting to lw0u4bBY02 at /kohadevbox/koha/C4/Circulation.pm line 1844. t/db_dependent/SIP/Transaction.t .. ok All tests successful. Files=1, Tests=10, 6 wallclock secs ( 0.04 usr 0.00 sys + 4.78 cusr 0.78 csys = 5.60 CPU) Result: PASS That doesn't look good right? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27166 --- Comment #13 from Nick Clemens <nick@bywatersolutions.com> --- (In reply to Victor Grousset/tuxayo from comment #12)
The tests pass in 19.11.x but I have an error message not in 20.05.x
kohadev-koha@9ddfdbbbd877:/kohadevbox/koha$ prove t/db_dependent/SIP/Transaction.t t/db_dependent/SIP/Transaction.t .. 7/10 AddReturn error: branch 'SIP2' not found. Reverting to bH8GNQ at /kohadevbox/koha/C4/Circulation.pm line 1844. AddReturn error: branch 'SIP2' not found. Reverting to bH8GNQ at /kohadevbox/koha/C4/Circulation.pm line 1844. t/db_dependent/SIP/Transaction.t .. 9/10 AddReturn error: branch 'SIP2' not found. Reverting to lw0u4bBY02 at /kohadevbox/koha/C4/Circulation.pm line 1844. AddReturn error: branch 'SIP2' not found. Reverting to lw0u4bBY02 at /kohadevbox/koha/C4/Circulation.pm line 1844. t/db_dependent/SIP/Transaction.t .. ok All tests successful. Files=1, Tests=10, 6 wallclock secs ( 0.04 usr 0.00 sys + 4.78 cusr 0.78 csys = 5.60 CPU) Result: PASS
That doesn't look good right?
I get the same warnings before this patch -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27166 Victor Grousset/tuxayo <victor@tuxayo.net> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to oldstable |Pushed to oldoldstable Version(s)|21.05.00,20.11.01,20.05.07 |21.05.00,20.11.01,20.05.07, released in| |19.11.13 --- Comment #14 from Victor Grousset/tuxayo <victor@tuxayo.net> --- My bad, thanks for doing the right check. Backported to 19.11.x branch for 19.11.13 :D -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27166 Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |caroline.cyr-la-rose@inlibr | |o.com -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org