[Bug 11913] New: Attributes generate error log during member entry
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11913 Bug ID: 11913 Summary: Attributes generate error log during member entry Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Patrons Assignee: koha-bugs@lists.koha-community.org Reporter: mtompset@hotmail.com QA Contact: testopia@bugs.koha-community.org CC: gmcharlt@gmail.com, kyle.m.hall@gmail.com SHOW_BCODE (or any other patron attribute) which is NULL will generate errors similar to: [Sun Mar 09 23:30:50 2014] [error] [client 192.168.45.23] [Sun Mar 9 23:30:50 2014] memberentry.pl: Use of uninitialized value $_ in hash element at /home/mtompset/kohaclone/members/memberentry.pl line 814. [Sun Mar 09 23:30:50 2014] [error] [client 192.168.45.23] [Sun Mar 9 23:30:50 2014] memberentry.pl: Use of uninitialized value in anonymous hash ({}) at /home/mtompset/kohaclone/members/memberentry.pl line 814. This is in part due to a poor way of copying the hash. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11913 M. Tompsett <mtompset@hotmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff Patch complexity|--- |Trivial patch -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11913 --- Comment #1 from M. Tompsett <mtompset@hotmail.com> --- Created attachment 25970 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=25970&action=edit Bug 11913 - Attributes generate error log during member entry In member/memberentry.pl, there were two lines like: my $newentry = { map { $_ => $entry->{$_} } %$entry }; These were in the 'sub patron_attributes_form'. They have been changed to: my $newentry = { %$entry }; Of course, indentation does not reflect actual indentation. They were discovered while testing another bug, which required editing a member record. TEST PLAN --------- 1) Make sure you have the SHOW_BCODE attribute. 2) Go edit a member. 3) Clear the SHOW_BCODE value. 4) Save. 5) Edit again. 6) Check the error log file. 7) apply patch. 8) Change the value for SHOW_BCODE (Yes/No) 9) Save. 10) Edit again. (tests change 1) 11) Clear the SHOW_BCODE 12) Save. 13) Edit again. (tests change 2) 14) Check the error log file. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11913 M. Tompsett <mtompset@hotmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Severity|enhancement |minor -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11913 M. Tompsett <mtompset@hotmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |mtompset@hotmail.com |ity.org | -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11913 Magnus Enger <magnus@enger.priv.no> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11913 --- Comment #2 from Magnus Enger <magnus@enger.priv.no> --- Created attachment 26052 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=26052&action=edit Bug 11913 - [SIGNED-OFF] Attributes generate error log during member entry In member/memberentry.pl, there were two lines like: my $newentry = { map { $_ => $entry->{$_} } %$entry }; These were in the 'sub patron_attributes_form'. They have been changed to: my $newentry = { %$entry }; Of course, indentation does not reflect actual indentation. They were discovered while testing another bug, which required editing a member record. TEST PLAN --------- 1) Make sure you have the SHOW_BCODE attribute. 2) Go edit a member. 3) Clear the SHOW_BCODE value. 4) Save. 5) Edit again. 6) Check the error log file. 7) apply patch. 8) Change the value for SHOW_BCODE (Yes/No) 9) Save. 10) Edit again. (tests change 1) 11) Clear the SHOW_BCODE 12) Save. 13) Edit again. (tests change 2) 14) Check the error log file. Signed-off-by: Magnus Enger <digitalutvikling@gmail.com> Tested with the SHOW_BCODE attribute, setting it to empty, Yes and No. The patch removes the error log messages, as described. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11913 M. Tompsett <mtompset@hotmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #25970|0 |1 is obsolete| | --- Comment #3 from M. Tompsett <mtompset@hotmail.com> --- Comment on attachment 25970 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=25970 Bug 11913 - Attributes generate error log during member entry Matched signed off version identically. Probably just forgot to be obsoleted. :) -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11913 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11913 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #26052|0 |1 is obsolete| | --- Comment #4 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 26411 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=26411&action=edit Bug 11913 - [SIGNED-OFF] Attributes generate error log during member entry In member/memberentry.pl, there were two lines like: my $newentry = { map { $_ => $entry->{$_} } %$entry }; These were in the 'sub patron_attributes_form'. They have been changed to: my $newentry = { %$entry }; Of course, indentation does not reflect actual indentation. They were discovered while testing another bug, which required editing a member record. TEST PLAN --------- 1) Make sure you have the SHOW_BCODE attribute. 2) Go edit a member. 3) Clear the SHOW_BCODE value. 4) Save. 5) Edit again. 6) Check the error log file. 7) apply patch. 8) Change the value for SHOW_BCODE (Yes/No) 9) Save. 10) Edit again. (tests change 1) 11) Clear the SHOW_BCODE 12) Save. 13) Edit again. (tests change 2) 14) Check the error log file. Signed-off-by: Magnus Enger <digitalutvikling@gmail.com> Tested with the SHOW_BCODE attribute, setting it to empty, Yes and No. The patch removes the error log messages, as described. Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> The existing code is really weird, I did not find any usefulness to have values in keys. No regression found. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11913 Galen Charlton <gmcharlt@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |RESOLVED Resolution|--- |DUPLICATE --- Comment #5 from Galen Charlton <gmcharlt@gmail.com> --- *** This bug has been marked as a duplicate of bug 11184 *** -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org