-
Notifications
You must be signed in to change notification settings - Fork 67
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Janeway notifications result in system error, don't send #3545
Comments
In further investigation, I added logging for all the e-mail addresses used in building a notification e-mail, and noticed that the from address isn't a string, it's a tuple. Which is presumably the result of this line:
|
A tuple in the format This suggests one of two potential problems: either Django's sanitization is not being invoked by your configured @hardyoyo can you confirm what from address is actually being passed to the SMTP server as well as confirm what email backend is configured on the faulty server? |
sure, with the line commented out, here's what from is set to: with the line in place, it's: The string sends an e-mail without error, the tuple does not. The EMAIL_BACKEND is set to: |
Thank you @hardyoyo. The line you logged is from Janeway's What we need to see is what the SMTP server itself is receiving from the application, so we can determine where the problem lies. My guess would be that the |
I was able to get the full text of the email message by enabling the file email backend. Here's the message that fails:
|
I suspect that the culprit here is on this line https://github.com/BirkbeckCTP/janeway/blob/master/src/utils/notify_plugins/notify_email.py#L24 I think |
I'm wrong... I created a tuple instead of a string on line 24, and got another error SMTP error.
There's definitely a bug here, where a tuple is getting sent to SMTP as if it's a string. I'll be darned if I can find it, though. This is a blocker for our continued testing and deployment of Janeway 1.5.x ... we require a working e-mail notification system. |
@mauromsl can we close this issue? |
Describe the bug
No
reply-to
is being set by the caller ofsend_email
Janeway version
5.1.0 RC3
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Email would successfully send.
Logs
After adding logging to
notify_email.py
:which yields this output when Janeway tries to send a submission confirmation message from a journal (demo-dev) and repository (ea-dev):
The text was updated successfully, but these errors were encountered: