Having a module named email causes an issue when running crawler.py. This is because email conflicts with an internal dependency of the package requests and causes it to import the wrong code.
Renamed email to email_utils
Updated import statement inside app.py
Feel free to suggest a different name - I was feeling uncreative.
Having a module named
email
causes an issue when runningcrawler.py
. This is becauseemail
conflicts with an internal dependency of the packagerequests
and causes it to import the wrong code.email
toemail_utils
app.py
Feel free to suggest a different name - I was feeling uncreative.
See this StackOverflow for an explanation of the error: https://stackoverflow.com/questions/32874326/python-email-module-importerror-no-module-named-utils
Example stacktrace: