Closed axce1 closed 10 years ago
sorry, my fault
How did you fix this error?
@santonocito it was api error key, check your key in settings.py
This isn't in the docs for djrill, but I fixed this error by adding DEFAULT_FROM_EMAIL = 'youremail@example.com' into your settings.py file. This is in addition to EMAIL_BACKEND = "djrill.mail.backends.djrill.DjrillBackend" and MANDRILL_API_KEY = "xxxxxx-xxxxxx-xxxxx".
I was getting this error too, and Google brought me here. If its not a error with your API key, then you'll get some information logged within Mandrill about the failed API call.
In my case, it was an invalid DEFAULT_FROM_EMAIL
. Django's default is webmaster@localhost
which Mandrill doesn't like because its not a valid domain. Change it to webmaster@example.com
or similar, and Mandrill's validation is satisfied.
for my case it was an invalid API key.
I had to log response.text on HTTP 500 to find out the reason. I think library should show the related error instead of just saying "failed to send to X".
I know it's failed to send, tell me something useful.
In case anyone else still has this problem, I was getting the same error by having typos in my template_name variable.
Exception Type: MandrillAPIError Exception Value:
Mandrill API response 500 Failed to send a message to [{'name': '', 'type': 'to', 'email': 'avirtgtdvbfo@dropmail.me'}], from example@example.com
Exception Location: /home/evgen/git/clever3.3/lib/python3.3/site-packages/djrill/mail/backends/djrill.py in _send, line 119