Closed nickmeny closed 10 months ago
Looks like you did not set your FLASK_APP
environment variable.
Looks like you did not set your
FLASK_APP
environment variable.
I have set the env var with the command set FLASK_APP=app.py
Okay, so then in app.py
you are not creating an application instance. See flasky.py in this repository and compare that against your app.py.
i found the solution!!! For dome reason my file name app.py dowsnt work with flask!!! When i rename it to flasky.py and set the FLASK_APP=flasky.py everything worked !!!
Did you have both app.py
and the app
package? That could be the problem, Python will see only one of them, since both have the name app
.
Oh yes I had. That was the problem. Thanks any way for your help
Hi,recently i bought your book and i am completly satisfied from your job!!! But, i want to implement your code at my project, specially the file organization. I make the config.py file as you have done in the book at page 87 with the only difference i loaded the var form a .env file . When i want to start the server at my pc i get that error
i have done everything up to page 97!!! pls help me (i have name the flasky.py file to app.py)