Python: getting started

Lesson 07 · 11 min

venv and pip

Dependencies live in a virtual environment, not in the system Python "for the whole computer".

python -m venv .venv creates a folder with its own interpreter. Activate it and pip install requests installs the package there. requirements.txt is a list so a colleague can repeat it. Install everything into the system Python and other people's projects break later.

Sign in to continue

The rest of this lesson opens after sign up

The first lesson of every course is open without an account. To read on, solve the practice and use Ask, create a free account or log in.