python


flask.cli.NoAppException: The file/path provided (new_app.py) does not appear to exist


I keep getting this error flask.cli.NoAppException: The file/path provided (new_app.py) does not appear to exist. Please verify the path is correct. If app is not on PYTHONPATH, ensure the extension is .py it goes away after I restart the Flask server.
I am running flask run in the correct directory where my app is. This just started happening after working for 2 weeks. I've read that it could be due to an import error, but I am not finding any modules that are not installed on my virutalenv.
from flask import Flask
app = Flask(__name__)
app.debug=True
Most likely you haven't set the FLASK_APP environment variable.
To run the application you can either use the flask command or
python’s -m switch with Flask. Before you can do that you need to tell
your terminal the application to work with by exporting the FLASK_APP
environment variable:
$ export FLASK_APP=hello.py
$ flask run * Running on http://127.0.0.1:5000/
If you are on Windows you need to use set
instead of export.
Alternatively you can use python -m flask:
$ export FLASK_APP=hello.py
$ python -m flask run * Running on http://127.0.0.1:5000/

Related Links

How i will insert matrices in an array in python
Python: How to increment a special-purpose string?
Change range withouth scaling in matplot
Python ViolinPlots
How do I plot a histogram of months with dates in matplotlib
Can't switch between pages in flask when video is buffering [duplicate]
Python: What is the most optimised way to count number of 0's from a list of 0's and 1's without using any in-build functions?
Theano: Fastest large-scale symmetric linear system solve
Parallel processing with Python class object
How to use faulhaber sequence in python?
Unexpected issue when encoding data using LabelEncoder and OneHotEncoder from sklearn
RGB to HSV wrong in colorsys?
KeyError: 'sessionId' in Python code for Gecko driver
How can global variables be accessed when using Multiprocessing and Pool?
What is the probability distribution used by a python sklearn classifier
NLTK ngrams is not working when i try to import

Categories

HOME
dotnetrdf
jdbc
symfony
websphere
ubuntu-16.04
jpanel
schemacrawler
data-science-experience
sudo
shipping
ipfs
google-classroom
image-recognition
qt-installer
dlib
react-leaflet
line-api
scaling
opera-mini
jogl
styles
countif
hhvm
avplayeritem
spring-ws
binutils
memsql
data-cleansing
opencart2.3
excel-2013
upnp
classpath
owl-api
vcard
hana-studio
aurelia-binding
vegan
spring-profiles
backup-strategies
spreedly
von-neumann
openpgp
active-model-serializers
s3cmd
wcf-security
tripwire
lftp
jdbi
startapp
openweathermap
double-buffering
proof
nstouchbar
applepayjs
decompress
component-pascal
openh264
mbaas
ticker
ruby-on-rails-2
tofixed
adler32
restivejs
cjson
galleriffic
easing
wcf-ria-services
tomcat5
date-format
picking
coldfusion-7
oai
rx-groovy
jython-2.7
ctrlp
pisa
inputaccessoryview
cloudpebble
funq
valence
wss
unison
circos
multiple-conditions
justgage
cbcentralmanager
cadisplaylink
hobo
hashalgorithm
charts4j
posting
junit3
msn
asp.net-routing
nt4

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App