Forums

How to access the shell of a Flask web app

Hi there! I am wondering if it's possible to access the shell of a web app in Flask, created through the auto set up of a new web app (web section ==>> add a new web app). I have to install a new module.

Thank you, Julio

Just use a Bash console. If you use virtual environment, activate it and install required module; if not, add --user flag while running pip install.

When I use the bash consol and the pip package, it installs on Python 2.7 (no venv was setup). The Flask App was auto creted using the said option in the web tab. The point is that is asks the user which Python version he's gonna work on and base his setup. So I assume I should be able to reach the console of this 3.7 Python version I selected.

Sure. Just run python3.7 in a console, or activate the correct virtualenv , if you're using a virtualenv.