Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/templates/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/sql-server-2005/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
未收到django allauth sendgrid密码重置电子邮件_Django_Sendgrid_Django Allauth - Fatal编程技术网

未收到django allauth sendgrid密码重置电子邮件

未收到django allauth sendgrid密码重置电子邮件,django,sendgrid,django-allauth,Django,Sendgrid,Django Allauth,我已将sendgrid集成到我的应用程序中,如下所示: SENDGRID_API_KEY = os.getenv('SENDGRID_API_KEY') EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend' EMAIL_HOST = 'smtp.sendgrid.net' EMAIL_HOST_USER = 'apikey' EMAIL_HOST_PASSWORD = SENDGRID_API_KEY EMAIL_PORT =

我已将sendgrid集成到我的应用程序中,如下所示:

SENDGRID_API_KEY = os.getenv('SENDGRID_API_KEY')
EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend'
EMAIL_HOST = 'smtp.sendgrid.net'
EMAIL_HOST_USER = 'apikey'
EMAIL_HOST_PASSWORD = SENDGRID_API_KEY
EMAIL_PORT = 587
EMAIL_USE_TLS = True
DEFAULT_FROM_EMAIL = "from@example.com"
我从manage.py shell运行了一个测试,如下所示,并收到了测试电子邮件

from django.core.mail import send_mail
send_mail('Subject here', 'Here is the message.', 'from@example.com', 
['to@example.com'])
在我的网站上,单击“忘记密码”并填写注册用户电子邮件后,该页面将重定向到显示“已发送电子邮件”的页面。但我没有收到任何电子邮件。没有调试信息,我无法找出哪里出错了


我在蟒蛇街,如果这有什么不同的话。我集成了allauth,因此用户可以通过电子邮件而不是用户名登录。

我在Pythonywhere上使用付费帐户。我发现了问题。ISP出于某种原因拒绝了该电子邮件。当我把帐户改成另一封电子邮件时,一切都很顺利。在sendgrid仪表板上看到一些请求已发出但未送达后,我意识到了这一点。

您在Pythonywhere上的帐户是免费的吗?免费帐户访问电子邮件服务的权限有限。看见