Suppress these warns during returning an item returns.pl: Use of uninitialized value $holdingBranch in string eq at /home/l2c2technologies/koha/circ/returns.pl line 623., referer: http://kohamaster.l2c2.co.in/cgi-bin/koha/members/readingrec.pl?borrowernumber=51 returns.pl: Use of uninitialized value $collectionBranch in string eq at /home/l2c2technologies/koha/circ/returns.pl line 623., referer: http://kohamaster.l2c2.co.in/cgi-bin/koha/members/readingrec.pl?borrowernumber=51
(In reply to Indranil Das Gupta from comment #0) > Suppress these warns during returning an item The warns have stopped for some reason. I need to investigate this a bit more.
Created attachment 40773 [details] [review] Bug 14487 - silence warns during checkin Test plan ========= 1/ check out an item and then check it back in. 1/ check the logs after the check-in to see the warns from returns.pl line 623 of : (a) Use of uninitialized value $holdingBranch (b) Use of uninitialized value $collectionBranch 2/ apply patch 3/ check out and check-in again. no warns are recorded this time.
(In reply to Indranil Das Gupta from comment #1) > (In reply to Indranil Das Gupta from comment #0) > > Suppress these warns during returning an item > > The warns have stopped for some reason. I need to investigate this a bit > more. please ignore comment #1
Created attachment 40783 [details] [review] Bug 14487 - silence warns during checkin Test plan ========= 1/ check out an item and then check it back in. 1/ check the logs after the check-in to see the warns from returns.pl line 623 of : (a) Use of uninitialized value $holdingBranch (b) Use of uninitialized value $collectionBranch 2/ apply patch 3/ check out and check-in again. no warns are recorded this time.
Created attachment 40784 [details] [review] Bug 14487 - silence warns during checkin Test plan ========= 1/ check out an item and then check it back in. 1/ check the logs after the check-in to see the warns from returns.pl line 623 of : (a) Use of uninitialized value $holdingBranch (b) Use of uninitialized value $collectionBranch 2/ apply patch 3/ check out and check-in again. no warns are recorded this time. NOTE: Under Debian Jessie, there are other messages. Additionally, this only corrects the line 623 ones. Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
[Fri Jul 03 17:00:54.327367 2015] [cgi:error] [pid 2960] [client 192.168.45.37:62532] AH01215: [Fri Jul 3 17:00:54 2015] returns.pl: Use of uninitialized value in hash element at /home/mtompset/kohaclone/circ/returns.pl line 469., referer: http://library-admin.debiankoha.ca/cgi-bin/koha/circ/returns.pl This probably applies to more than just Debian Jessie. [Fri Jul 03 17:00:54.334787 2015] [cgi:error] [pid 2960] [client 192.168.45.37:62532] AH01215: [Fri Jul 3 17:00:54 2015] returns.pl: CGI::param called in list context from package main line 620, this can lead to vulnerabilities. See the warning in "Fetching the value or values of a single named parameter" at /usr/share/perl5/CGI.pm line 436., referer: http://library-admin.debiankoha.ca/cgi-bin/koha/circ/returns.pl This probably applies to only Debian Jessie context. Moving this back to ASSIGNED, since I believe 469 should be fixed at least based on the bug description given.
(In reply to M. Tompsett from comment #6) > [Fri Jul 03 17:00:54.327367 2015] [cgi:error] [pid 2960] [client > 192.168.45.37:62532] AH01215: [Fri Jul 3 17:00:54 2015] returns.pl: Use of > uninitialized value in hash element at > /home/mtompset/kohaclone/circ/returns.pl line 469., referer: > http://library-admin.debiankoha.ca/cgi-bin/koha/circ/returns.pl Trigger case: check in something that isn't checked out.
Created attachment 40785 [details] [review] Bug 14487: Noise best detected under Debian 8 The first error is caused by the fact that $messages->{'IsPermanent'} is undefined. The second error is caused by querying the CGI parameter 'barcode' inside a function call. This is not required. There is a variable $barcode set with the parameter. Changed to use the variable. TEST PLAN ---------- 1) Test first patch. 2) Clear the log 3) Put in a barcode which is not checked out. 4) Check the log. -- should be two errors. One about a hash, the other will only be detectable under Debian 8. 5) Apply this second patch 6) Clear the log 7) Put in a barcode which is not checked out. 8) Check the log. -- should be empty. 9) run koha qa test tools
Created attachment 40788 [details] [review] Bug 14487: Noise best detected under Debian 8 The first error is caused by the fact that $messages->{'IsPermanent'} is undefined. The second error is caused by querying the CGI parameter 'barcode' inside a function call. This is not required. There is a variable $barcode set with the parameter. Changed to use the variable. TEST PLAN ---------- 1) Test first patch. 2) Clear the log 3) Put in a barcode which is not checked out. 4) Check the log. -- should be two errors. One about a hash, the other will only be detectable under Debian 8. 5) Apply this second patch 6) Clear the log 7) Put in a barcode which is not checked out. 8) Check the log. -- should be empty. 9) run koha qa test tools Signed-off-by: Indranil Das Gupta (L2C2 Technologies) <indradg@gmail.com>
All patches appear to be signed off, marking as such
(In reply to Nick Clemens from comment #10) > All patches appear to be signed off, marking as such I happen to know that Indranil did not have a Debian 8 VM, so I don't think he accurately triggered the noise, though he did confirm that it still worked as expected. That is why it was still needs sign off. Like I said, this needs a Debian 8 (not Jessie release candidate) updated to test the second patch fully (because otherwise you won't likely see the messages as in comment #6. That's why I'm sticking it back to Needs Sign off.
Created attachment 41082 [details] [review] Bug 14487 - silence warns during checkin Test plan ========= 1/ check out an item and then check it back in. 1/ check the logs after the check-in to see the warns from returns.pl line 623 of : (a) Use of uninitialized value $holdingBranch (b) Use of uninitialized value $collectionBranch 2/ apply patch 3/ check out and check-in again. no warns are recorded this time. NOTE: Under Debian Jessie, there are other messages. Additionally, this only corrects the line 623 ones. Signed-off-by: Mark Tompsett <mtompset@hotmail.com> Signed-off-by: Nick Clemens <nick@quecheelibrary.org>
Created attachment 41083 [details] [review] Bug 14487: Noise best detected under Debian 8 The first error is caused by the fact that $messages->{'IsPermanent'} is undefined. The second error is caused by querying the CGI parameter 'barcode' inside a function call. This is not required. There is a variable $barcode set with the parameter. Changed to use the variable. TEST PLAN ---------- 1) Test first patch. 2) Clear the log 3) Put in a barcode which is not checked out. 4) Check the log. -- should be two errors. One about a hash, the other will only be detectable under Debian 8. 5) Apply this second patch 6) Clear the log 7) Put in a barcode which is not checked out. 8) Check the log. -- should be empty. 9) run koha qa test tools Signed-off-by: Indranil Das Gupta (L2C2 Technologies) <indradg@gmail.com> Signed-off-by: Nick Clemens <nick@quecheelibrary.org>
Created attachment 41173 [details] [review] [PASSED QA] Bug 14487 - silence warns during checkin Test plan ========= 1/ check out an item and then check it back in. 1/ check the logs after the check-in to see the warns from returns.pl line 623 of : (a) Use of uninitialized value $holdingBranch (b) Use of uninitialized value $collectionBranch 2/ apply patch 3/ check out and check-in again. no warns are recorded this time. NOTE: Under Debian Jessie, there are other messages. Additionally, this only corrects the line 623 ones. Signed-off-by: Mark Tompsett <mtompset@hotmail.com> Signed-off-by: Nick Clemens <nick@quecheelibrary.org> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Created attachment 41174 [details] [review] [PASSED QA] Bug 14487: Noise best detected under Debian 8 The first error is caused by the fact that $messages->{'IsPermanent'} is undefined. The second error is caused by querying the CGI parameter 'barcode' inside a function call. This is not required. There is a variable $barcode set with the parameter. Changed to use the variable. TEST PLAN ---------- 1) Test first patch. 2) Clear the log 3) Put in a barcode which is not checked out. 4) Check the log. -- should be two errors. One about a hash, the other will only be detectable under Debian 8. 5) Apply this second patch 6) Clear the log 7) Put in a barcode which is not checked out. 8) Check the log. -- should be empty. 9) run koha qa test tools Signed-off-by: Indranil Das Gupta (L2C2 Technologies) <indradg@gmail.com> Signed-off-by: Nick Clemens <nick@quecheelibrary.org> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Patches pushed to master. Thanks Indranil and Mark!
Pushed to 3.20.x will be in 3.20.3
Pushed to 3.18.x, will be in 3.18.10.
Pushed to 3.16.x, will be in 3.16.14