Skip to content Skip to sidebar Skip to footer

Flask.cli.noappexception: Failed To Find Application In Module?

I am following the tutorial on http://flask.pocoo.org/docs/1.0/tutorial/factory/ I am just starting and it seemed simple but when I had the app running, I am just wondering why it

Solution 1:

Try going back to the flask-tutorial/ directory, then run $ flask run command.

Importing flaskr must be done from the flask-tutorial/ directory (which contains flaskr).

Solution 2:

This is an issue with python not able to find the app in the path.

Add this code and test:

import sys

print(sys.path)

Check if the printed path array has containing folder's path. If not, for a quick fix use sys.path.append('./')

Otherwise you will have to investigate where you are messing with the python path.

Post a Comment for "Flask.cli.noappexception: Failed To Find Application In Module?"