On Mon, Jun 27, 2011 at 7:02 AM, Kyle Gong <k...@kiwiinteractive.com> wrote:
> I was trying to avoid setting up a mail server by just sending through
> gmail's SMTP server. It is sending correctly through
> django.utils.log.AdminEmailHandler and it was my understanding that they
> worked through the same mechanisms?

My apologies -- I didn't register that you were using connecting
directly to GMail's servers to send mail.

You haven't provided your mail settings, so it's impossible to know
exactly what is going wrong, but my best guess would be that you don't
have the EMAIL_USE_TLS setting enabled. GMail's servers use TLS to
provide on-the-wire security, but Django has this turned off by
default (since most mail servers don't enable TLS by default).

As far as debugging this problem goes -- my advice would be to start
lower in the stack. I can guarantee that if your email configuration
is right, then 404 mails will be sent -- the real issue is whether the
email configuration is correct. To verify this, use the mail APIs
directly. From a Python prompt on your sever:

>>> from django.core import mail
>>> mail.send_mail("A subject", "This is the message", "m...@example.com", 
>>> ["recipi...@example.com"])

substituting "m...@example.com" with your own address, and
"recipi...@example.com" with another email address you can test with.
This call should return 1, indicating that 1 email was sent. If it
doesn't, or it raises an error, you should get some indication of what
has gone wrong.

Yours,
Russ Magee %-)

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to