Created attachment 4037 [details] Simple patch to fix the issue Have just tracked down that email notices to clients (for overdues) were not being sent because the "to_address" was not set. The simple patch attached fixes it for us... We're running 3.2.2 - but th fix will apply to the latest git.
We are using 3.2.2 with overdue notices in production. One of our libraries started with fines and overdue notices at the beginning of this week. They told me overdue notices were successfully sent out, one to the librarian for testing even, and I saw nothing wrong in the database. I am wondering if this problem might be related to configuration?
Changing the status to "PATCH-Sent" and "Needs Signoff".
I am still wondering about this. If the to_address is no set - afaik - the address will be taken from the patron account before the notice is sent out. We have a lot of libraries using notices with 3.2.2
There was some discussion on the mailing list about this. One hint is to check the setting for AutoEmailPrimaryAddress. The to_address will be populated once the process_message_queue process was run. http://lists.katipo.co.nz/pipermail/koha/2011-November/031064.html I tend to mark this INVALID - ok?
Have tested, and it does work as noted in Comment 4 when the AutoEmailPrimaryAddress is set to "first valid". A few suggestions though: 1) That the system preference "AutoEmailPrimaryAddress" be made distinct from the "AutoEmailOpacUser" prefernce. I don't want to send an email to newly created patrons with their account details, but I *do* want to send them overdue notices. (Under 3.4.2 the preferences seem to be joined together?) 2) That process_message_queue should update the "to_address" field in the "message_queue" table upon sending the email. That way, there's a historical record of which email address the notice was actually sent to (even if the email address for a user is changed in the future)
I agree with Comment 5, I will switch this from patch sent, and hopefully we will get a patch to do both 1 and 2 in comment 5
Created attachment 6508 [details] [review] Bug 6302: Separate AutoEmailPrimaryAdress and AutoEmailOpacUser AutoEmailPrimaryAddress is not only used for the patron account mails, but also for overdues and other email notices to patrons. This patch separates the system preferences in the system preference editor. To test: - Check Patrons tab shows both system preferences separated - Check you can still change the settings
Created attachment 6605 [details] [review] [SIGNED-OFF] Bug 6302: Separate AutoEmailPrimaryAdress and AutoEmailOpacUser AutoEmailPrimaryAddress is not only used for the patron account mails, but also for overdues and other email notices to patrons. This patch separates the system preferences in the system preference editor. To test: - Check Patrons tab shows both system preferences separated - Check you can still change the settings Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
If I am not mistaken, this patch only resolves the first point of Comment 5 and is actually just a cosmetic change. The second point refers to updating the to_address in sub _send_message_by_email in Letters.pm. I would propose to put this report into hold until we can also consider the patch solving the second point. The first patch is OK, but setting the status to Failed QA in order to reflect the on hold status.
Hi Marcel, is there a reason the 'cosmetic' change can not go in now? It would make it easier for people to get their configuration right and send out mails.
(In reply to comment #10) > Hi Marcel, > is there a reason the 'cosmetic' change can not go in now? It would make it > easier for people to get their configuration right and send out mails. Hi Katrin, It may speed up receiving the second patch ;) But if it would really help, I do not oppose pushing it.
I don't think I will have time to work on the second part of the patch. :(
(In reply to comment #12) > I don't think I will have time to work on the second part of the patch. :( Will take a look.
Created attachment 6789 [details] [review] Follow up for updating queue
Second patch needs signoff ! Please test..
Created attachment 6806 [details] [review] [SIGNED-OFF] Bug 6302: Separate AutoEmailPrimaryAdress and AutoEmailOpacUser AutoEmailPrimaryAddress is not only used for the patron account mails, but also for overdues and other email notices to patrons. This patch separates the system preferences in the system preference editor. To test: - Check Patrons tab shows both system preferences separated - Check you can still change the settings Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com> Signed-off-by: Koustubha Kale <kmkale@anantcorp.com>
Created attachment 6807 [details] [review] [SIGNED-OFF] 6302 follow up Updates to_address in message queue when sending an email (when needed). Signed-off-by: Koustubha Kale <kmkale@anantcorp.com>
(In reply to comment #16) > Created attachment 6806 [details] [review] > [SIGNED-OFF] Bug 6302: Separate AutoEmailPrimaryAdress and AutoEmailOpacUser > > AutoEmailPrimaryAddress is not only used for the patron account mails, but > also for overdues and other email notices to patrons. > > This patch separates the system preferences in the system preference editor. > > To test: > - Check Patrons tab shows both system preferences separated > - Check you can still change the settings > > Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com> > Signed-off-by: Koustubha Kale <kmkale@anantcorp.com> 1) Verified that prior to applying patch one the System preferences AutoEmailOpacUser and AutoEmailPrimaryAddress were combined. 2) after applying first patch, verified that there were two separate system preferences for AutoEmailOpacUser and AutoEmailPrimaryAddress
(In reply to comment #17) > Created attachment 6807 [details] [review] > [SIGNED-OFF] 6302 follow up > > Updates to_address in message queue when sending an email (when needed). > > Signed-off-by: Koustubha Kale <kmkale@anantcorp.com> 3) Verified that before applying patch two, after running process_message_queue.pl, the to_address field in table message_queue had null for Item Overdue notice. 4) Verified that after applying patch two , after running process_message_queue.pl, the to_address field in table message_queue had patrons email address in it.
QA comment: both patches are small, good code, no specific comment no change in perlcritic (19 warnings before, 19 after applying the patch) test plan: see comment 5 to understand what those patches are doing passed QA patches pushed, please test