Run flask server with python command

Question:

Can you run a flask server with

python main.py

instead of the export flask app thingy?

Asked By: Sonicx180

||

Answers:

yes, assuming your main.py file contains

if __name__ == '__main__':
    app.run()
Answered By: Andrew Clark
Categories: questions Tags: ,
Answers are sorted by their score. The answer accepted by the question owner as the best is marked with
at the top-right corner.