Flask AttributeError: module 'app' has no attribute 'run'
I fixed this issue by renaming the app
directory to something else (e.g. webapp
). Using from webapp import app
does the trick. This seems to be because package directory names take precedence over module names when importing. Perhaps using __path__
would allow one to get around this.