Seeing this one in 23.11. Not seen before in 22.11. [2025/02/28 10:20:09] [WARN] DBIx::Class::Storage::DBI::insert(): Missing value for primary key column 'borrowernumber' on BorrowerModification - perhaps you forgot to set its 'is_auto_increment' attribute during add_columns()? Treating 'borrowernumber' implicitly as an autoinc, and attempting value retrieval at /usr/share/koha/Koha/Object.pm line 172 Coming from opac-memberentry.pl when storing Koha::Patron::Modification in the create step. Probably adding a borrowernumber 0 in the hash should be enough to get rid of this probably innocent warning?
Created attachment 178891 [details] [review] Bug 39226: Add borrowernumber 0 when creating patron modification Test plan: Test with and without this patch. Verify that you see no warn with Missing value for primary key column anymore in plack-opac-error. Enable self registration. Register a new patron.
It's weird, for some reason I can't reproduce this issue on main.
(In reply to Paul Derscheid from comment #2) > It's weird, for some reason I can't reproduce this issue on main. What is value of PatronSelfRegistrationVerifyByEmail ?
Created attachment 179956 [details] [review] Bug 39226: Add borrowernumber 0 when creating patron modification Test plan: Test with and without this patch. Verify that you see no warn with Missing value for primary key column anymore in plack-opac-error. Enable self registration. Register a new patron. Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Created attachment 179965 [details] [review] Bug 39226: (follow-up) Similar change for the cud-update branch Resolve DBIx::Class::Storage::DBI::insert(): Missing value for primary key column 'verification_token' on BorrowerModification Test plan: Update details for existing borrower.
I think it has to be `$borrower_changes{verification_token} = q{};` instead, huh?
Created attachment 179973 [details] [review] Bug 39226: (follow-up) Similar change for the cud-update branch Resolve DBIx::Class::Storage::DBI::insert(): Missing value for primary key column 'verification_token' on BorrowerModification Test plan: Update details for existing borrower.
(In reply to Paul Derscheid from comment #6) > I think it has to be > `$borrower_changes{verification_token} = q{};` > instead, huh? Sure :) Copy and paste..
Created attachment 179981 [details] [review] Bug 39226: Add borrowernumber 0 when creating patron modification Test plan: Test with and without this patch. Verify that you see no warn with Missing value for primary key column anymore in plack-opac-error. Enable self registration. Register a new patron. Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Created attachment 179982 [details] [review] Bug 39226: (follow-up) Similar change for the cud-update branch Resolve DBIx::Class::Storage::DBI::insert(): Missing value for primary key column 'verification_token' on BorrowerModification Test plan: Update details for existing borrower. Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Ah, sorry. Forgot that I already SOd.
But this is easily PQA, already tested everything.
Created attachment 180026 [details] [review] Bug 39226: Add borrowernumber 0 when creating patron modification Test plan: Test with and without this patch. Verify that you see no warn with Missing value for primary key column anymore in plack-opac-error. Enable self registration. Register a new patron. Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de> Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Created attachment 180027 [details] [review] Bug 39226: (follow-up) Similar change for the cud-update branch Resolve DBIx::Class::Storage::DBI::insert(): Missing value for primary key column 'verification_token' on BorrowerModification Test plan: Update details for existing borrower. Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de> Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
(In reply to Emily Lamancusa (emlam) from comment #14) > Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de> > Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov> Thx
Pushed for 25.05! Well done everyone, thank you!