Skip to content

Virtual environment

A virtual environment is a private set of Python packages for one project. What you install there stays there, so each project keeps the versions it needs.

Select any words here to ask your Maestro about them.

In VS Code you create one from the Command Palette: Python: Create Environment → Venv. It shows up as a .venv folder inside your project, and you pick it as your notebook's kernel.

One project can run Altair 5 while an older one keeps Altair 4, each in its own environment.

R users: it's the same idea as renv.

Ask your Maestro about Virtual environment

It answers from the free course page closest to this word, the way it answers while you study.

Example

You: What does "Virtual environment" mean, in plain words?

Your Maestro: I'll explain it with a case of yours: it sticks better than a definition. Shall we make one for your project?

Asking about: Answers from the page "Why does my CSV look wrong?"

Only this browser keeps what you ask here. How it works

In Maestro's courses

Learn more

  • Package

    A package is a bundle of code someone else wrote that you install to give Python new tools. pandas and Altair are packages.

  • Command Palette

    The Command Palette is VS Code's search box for every command it has. Open it with Ctrl+Shift+P (Cmd+Shift+P on a Mac), type a few words and press Enter.

  • VS Code

    VS Code (Visual Studio Code) is a free code editor from Microsoft. With its Python and Jupyter extensions, it runs notebooks right inside the editor.

The whole glossary