Flask-Mail not sending emails, no error is being reported

前端 未结 3 2009
隐瞒了意图╮
隐瞒了意图╮ 2021-01-17 15:06

All, I\'m trying to setup flask-mail to send notifications to my email when a user registers. I\'m getting no error messages from the script used to send the email, but not

3条回答
  •  鱼传尺愫
    2021-01-17 15:20

    tbicr has the most likely fix, check MAIL_SUPPRESS_SEND first.

    What ended up burning me (being new to flask) is that when you instantiate your Mail() object, be sure it's after you've set your app.config values. The Mail() object doesn't go back and look at these values after the fact, so they will default to bad values. What's frustrating is that you won't see any errors when you try to send messages with the default/bad values. At least not as of my posting.

提交回复
热议问题