In this video we work in Visual Studio Code that already has the basic Python Extensions. We run python -m venv venv to establish a virtual environment. Next, we made sure the the current user had the appropriate script running permissions in PowerShell (this was a Windows system). Then we activated the virtual environment and ran the command pip install Flask. After that we created a .py file in the virtual environment and added the basic "Hello World" code to have Flask act as a virtual web server and serve up a very simple page. We invoked the flask app from the command line (terminal) and accessed the resulting page.
- Жыл бұрын
Flask Hello World: Setting up a python virtual environment (venv) in VS Code & installing Flask
- Рет қаралды 2,578
Пікірлер: 10