Closes issue #17732: ignore install-directory specific options in

distutils.cfg when a venv is active.
This commit is contained in:
Georg Brandl 2013-05-12 12:36:07 +02:00
parent b3bd624a55
commit 521ed52131
5 changed files with 87 additions and 3 deletions

View file

@ -645,6 +645,11 @@ environment variables, such as Mac OS 9, the configuration variables supplied by
the Distutils are the only ones you can use.) See section :ref:`inst-config-files`
for details.
.. note:: When a :ref:`virtual environment <venv-def>` is activated, any options
that change the installation path will be ignored from all distutils configuration
files to prevent inadvertently installing projects outside of the virtual
environment.
.. XXX need some Windows examples---when would custom installation schemes be
needed on those platforms?

View file

@ -57,6 +57,10 @@ Creating virtual environments
:attr:`sys.exec_prefix` is the same as :attr:`sys.base_exec_prefix` (they
all point to a non-venv Python installation).
When a venv is active, any options that change the installation path will be
ignored from all distutils configuration files to prevent projects being
inadvertently installed outside of the virtual environment.
API
---