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
Error sending e-mail with accented characters #83
Comments
I just subscribed in my production environment (with SMTP backend) with name "André" without any problems. Is this related to previous issue #82? You see "Due to a technical error we were not able to submit ..." in browser and you took this error from the logger? Which version of python are you using? Do you have non-default In #82 you mentioned about installing previous version of django-newsletter, does this error occur in fresh install of latest master or in upgraded from previous versions? May be related to: |
Hi jkuczm, Thank you for you reply. I've defined in the settings.py DEFAULT_CHARSET = 'utf-8' But does not work either with this settings. To make it work I have to do the described here: http://stackoverflow.com/questions/15831209/django-1-5-unicodeencodeerror-using-attach-alternative-in-emails There is other way of doing this without changing the source code of Django-newsletter? Best Regards, |
It's crucial, which version of python are you using? This looks like a problem in communication between specific versions of Django and specific versions of python. There's a pending Django ticket (20230). I don't think problem is in django-newsletter. |
@lopesandre Don't think this is a problem related to django-newsletter either - but feel free to try and convince me otherwise. @jkuczm Thanks a lot for your feedback on this one (and others)! |
It is a problem with django-newsletter. Facts: -Unicode is permitted everywhere but in the addresses. From Django docs:
-Say I have a chinese user of name 李志 and email some_email@gmail.com
Clearly best answer is #2 so that makes it a problem of django-newsletter! |
Fyi, Django < 1.10 had a problem with unicode in e-mail address encodings
|
hey, django 1.10 is still in alpha. Most users are not in django1.10. Most probably lot-s of emails are not being sent because of this (and maybe admins dont even realize!) |
It was just some extra context around the issue :) it should be handled for
|
Ah! I cant upgrade to django 1.9 yet because of my dependencies, so I still need my fix :) |
Could you please attach the error traceback so we can see where it fails? |
Hi,
When I try to subscribe with a non registered user using the form with "Name" and "Email", if I use an accented name, the E-mail is not sent. The error is:
UnicodeEncodeError('ascii', u'Dear Andr\xe9,\r\n\r\nyou, or someone in your name requested a subscription to Gui Chestnut Alert.\r\n\r\nIf you would like to confirm your subscription, please follow this activation link:\r\nhttp://example.com/en/new-season-start-alert/gui-chestnut-alert/subscription/some@email.com/subscribe/activate/1acb3e89050e876268c764fbca80c88db5423a28/\r\n\r\nKind regards,\r\nGui Chestnut Portugal', 9, 10, 'ordinal not in range(128)')
Here I'm trying to send the Name "André"
I've catch this error on views.py, class ActionRequestView, method form_valid
Using Master branch, Django 1.5.1
The text was updated successfully, but these errors were encountered: