Error in python Flask-Mail, I have KeyError MAIL_DEFAULT_SENDER or other

Solution
app.config['MAIL_DEFAULT_SENDER'] = os.environ.get('MAIL_DEFAULT_SENDER')
app.config['MAIL_DEFAULT_SENDER'] = os.environ.get('MAIL_DEFAULT_SENDER', 'default mail sender')