Summary: | Error when importing patrons, Column 'checkprevcheckout' cannot be null | ||
---|---|---|---|
Product: | Koha | Reporter: | Kyle M Hall (khall) <kyle> |
Component: | Tools | Assignee: | Kyle M Hall (khall) <kyle> |
Status: | CLOSED FIXED | QA Contact: | Marcel de Rooy <m.de.rooy> |
Severity: | blocker | ||
Priority: | P5 - low | CC: | f.demians, julian.maurice, m.de.rooy, mtompset |
Version: | Main | ||
Hardware: | All | ||
OS: | All | ||
Change sponsored?: | --- | Patch complexity: | Trivial patch |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: | Version(s) released in: | ||
Circulation function: | |||
Bug Depends on: | 6906 | ||
Bug Blocks: | 16889, 17034, 17080 | ||
Attachments: |
Bug 16917 - Error when importing patrons, Column 'checkprevcheckout' cannot be null
Test CSV File Bug 16917 - Error when importing patrons, Column 'checkprevcheckout' cannot be null Bug 16917 - Error when importing patrons, Column 'checkprevcheckout' cannot be null |
Description
Kyle M Hall (khall)
2016-07-13 15:40:54 UTC
Created attachment 53378 [details] [review] Bug 16917 - Error when importing patrons, Column 'checkprevcheckout' cannot be null Error: DBIx::Class::Storage::DBI::_dbh_execute(): Column 'checkprevcheckout' cannot be null at C4/Members.pm line 697 Test Plan: 1) Attempt to import a patron via csv 2) Note the error 3) Apply this patch 4) Repeat the import 5) No error! I added a line: die "TRIGGER!" if !$new_member->{checkprevcheckout}; into C4::Members just above the change, and then ran prove t/db_dependent. TRIGGERED: t/db_dependent/Budgets.t TRIGGERED: t/db_dependent/Circulation.t RELATED: t/db_dependent/DecreaseLoanHighHolds.t TRIGGERED: t/db_dependent/Holds.t TRIGGERED: t/db_dependent/Letters.t TRIGGERED: t/db_dependent/Members.t TRIGGERED: t/db_dependent/Ratings.t TRIGGERED: t/db_dependent/Reserves.t TRIGGERED: t/db_dependent/Serials_2.t TRIGGERED: t/db_dependent/Suggestions.t So, now to remove that line of code and run these tests. Tracing down failures: t/db_dependent/Circulation.t t/db_dependent/DecreaseLoanHighHolds.t t/db_dependent/Reserves.t These all fail on master too, so I'll fall back to the provided test plan. Please provide a sample patron CSV that triggers issue. I attempted with checkprevcheckout deleted, and then set to 'null'. I tried both new and overwrite. Created attachment 53398 [details]
Test CSV File
This file caused the error for me.
Created attachment 53405 [details] [review] Bug 16917 - Error when importing patrons, Column 'checkprevcheckout' cannot be null Error: DBIx::Class::Storage::DBI::_dbh_execute(): Column 'checkprevcheckout' cannot be null at C4/Members.pm line 697 Test Plan: 1) Attempt to import a patron via csv 2) Note the error 3) Apply this patch 4) Repeat the import 5) No error! NOTE: Given that all the other tests ran (comment #2), except those in comment #3, I resorted to following the test plan above using the attachment provided in comment #5. I believe the issues in comment #3 constitute other bugs which need fixing and are unrelated this bug. Applying the patch does resolve the error triggered, and the code is good. Signed-off-by: Mark Tompsett <mtompset@hotmail.com> Created attachment 53412 [details] [review] Bug 16917 - Error when importing patrons, Column 'checkprevcheckout' cannot be null Error: DBIx::Class::Storage::DBI::_dbh_execute(): Column 'checkprevcheckout' cannot be null at C4/Members.pm line 697 Test Plan: 1) Attempt to import a patron via csv 2) Note the error 3) Apply this patch 4) Repeat the import 5) No error! NOTE: Given that all the other tests ran (comment #2), except those in comment #3, I resorted to following the test plan above using the attachment provided in comment #5. I believe the issues in comment #3 constitute other bugs which need fixing and are unrelated this bug. Applying the patch does resolve the error triggered, and the code is good. Signed-off-by: Mark Tompsett <mtompset@hotmail.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Pushed to master for 16.11! Pushed in 16.05. Will be in 16.05.02. Reverted. Shouldn't be in 16.05. Not needed in 3.22.x |