问题
I'm trying to setup SendGrid with Google App Engine using python, following the instructions here: https://developers.google.com/appengine/docs/python/mail/sendgrid
I can successfully use the sample app to send mail: https://github.com/sendgrid/google-python-sample-app
but this is based on older sendgrid python code, and I'd like to use the latest version: https://github.com/sendgrid/sendgrid-python/tree/master/sendgrid
I tried following the guidance here: sendgrid google app engine python DistributionNotFound
...manually installing sendgrid and smtpapi, and then copying the folders to my gae directory, and then moving smtpapi to the sendgrid directory...
but got the error:
"ImportError: cannot import name Sendgrid"
回答1:
I think there may be a clue in the error message, I think you have referenced Sendgrid (with a capital S) rather than sendgrid (lowercase)?
来源:https://stackoverflow.com/questions/25690799/importerror-no-module-named-smtpapi-for-sendgrid-in-google-app-engine