Skip to content

Commit a6846d4

Browse files
vsajipvstinner
andauthored
gh-109414: Add some basic information about venvs in the introduction. (GH-109440)
Co-authored-by: Victor Stinner <[email protected]>
1 parent 0b38ce4 commit a6846d4

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

Doc/library/venv.rst

+19
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,25 @@ When used from within a virtual environment, common installation tools such as
3030
`pip`_ will install Python packages into a virtual environment
3131
without needing to be told to do so explicitly.
3232

33+
A virtual environment is (amongst other things):
34+
35+
* Used to contain a specific Python interpreter and software libraries and
36+
binaries which are needed to support a project (library or application). These
37+
are by default isolated from software in other virtual environments and Python
38+
interpreters and libraries installed in the operating system.
39+
40+
* Contained in a directory, conventionally either named ``venv`` or ``.venv`` in
41+
the project directory, or under a container directory for lots of virtual
42+
environments, such as ``~/.virtualenvs``.
43+
44+
* Not checked into source control systems such as Git.
45+
46+
* Considered as disposable -- it should be simple to delete and recreate it from
47+
scratch. You don't place any project code in the environment
48+
49+
* Not considered as movable or copyable -- you just recreate the same
50+
environment in the target location.
51+
3352
See :pep:`405` for more background on Python virtual environments.
3453

3554
.. seealso::

0 commit comments

Comments
 (0)