Answer the question
In order to leave comments, you need to log in
How to make Run config in PyCharm for Flask using Pipenv?
I created a project where I use pipenv, then I installed flask itself. Through the terminal, all the rules come out
pipenv run flask run
. But with the config for launching, I got confused. Is it possible to do everything through a shell script?
Answer the question
In order to leave comments, you need to log in
In general, the best and most normal option is to create a file and build on it.
# run.py
from app import create_app
if __name__ == '__main__':
app = create_app().run()
# app/__init__.py
from flask import Flask
def create_app():
app = Flask(__name__)
app.config.from_object('app.config')
return app
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question