[Bug 41965] New: Mismatch between SMTP server and FROM branch in multi-branch notice sending
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41965 Bug ID: 41965 Summary: Mismatch between SMTP server and FROM branch in multi-branch notice sending Initiative type: --- Sponsorship --- status: Product: Koha Version: Main Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Staff interface Assignee: koha-bugs@lists.koha-community.org Reporter: hammat.wele@inlibro.com QA Contact: testopia@bugs.koha-community.org CC: gmcharlt@gmail.com -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41965 Hammat wele <hammat.wele@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |hammat.wele@inlibro.com |ity.org | -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41965 Hammat wele <hammat.wele@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |caroline.cyr-la-rose@inlibr | |o.com, | |philippe.blouin@inlibro.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41965 --- Comment #1 from Hammat wele <hammat.wele@inlibro.com> --- Created attachment 194400 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=194400&action=edit Bug 41965: Mismatch between SMTP server and FROM branch in multi-branch notice sending In a multi-branch setup, when sending notices (e.g., overdue notices), the From address may correctly correspond to the branch where the checkout occurred, but the SMTP server used to send the email is taken from another branch (often the patron’s home library or the system default). This leads to email delivery failures. SMTP and From must always be derived from the same logical branch. To Reproduce You must have: 1- A default SMTP server defined in koha-conf.xml: <smtp_server> <host>smtp.gmail.com</host> <port>587</port> <timeout>5</timeout> <ssl_mode>STARTTLS</ssl_mode> <user_name>email@gmail.com</user_name> <password>ertyuytre</password> <debug>1</debug> </smtp_server> 2- A second SMTP server configured in Koha. Configuration Steps 1- Go to Administration -> SMTP servers 2- Create a new SMTP server named Midway 3- Go to Administration -> Libraries 4- Edit Springfield 1- Email: springfield@example.com 2- SMTP server: Default 5- Edit Midway 1- Email: midway@example.com 2- SMTP server: Midway 6- Click your username -> Set library -> switch to Midway 7- Find a borrower belonging to Springfield and ensure they have an email 8- Find a record with items 9- Checkout an item to that borrower with a past due date 10- Run: ./misc/cronjobs/overdue_notices.pl 11- Check message_queue table ==> from_address = midway@example.com 12- Run: ./misc/cronjobs/process_message_queue.pl -v ==> The SMTP used is the Default one, Expected: Midway SMTP ==> The SMTP server used must correspond to the branch that owns the from_address. 13- Apply the patch 14- Run prove t/db_dependent/Letters.t ==> Test should pass 15- Repeat step 12 ==> The smtp used is the Midway one -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41965 Hammat wele <hammat.wele@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41965 --- Comment #2 from Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> --- Testing notes : - Steps 1 & 2 : KTD already comes with a default SMTP server in koha-conf, so I simply added a fake one called Midway in Admin > SMTP servers - Between steps 9 & 10 : in KTD, there are no default configuration for overdue notices. Go to Tools > Overdue notice/status triggers. Fill out at least the "First" tab by adding a delay value (I used 7), letter (I used Overdue notice (ODUE)), and checking the email box for at least the patron category of the patron in step 7 (I did it for all patron categories just in case) - Additional test : I tried with a different value in OverdueNoticeFrom and it always uses the SMTP from the from address, whether it be from the patron's library, or item library I can't sign off bc I work with Hammat... -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org