This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author eryksun
Recipients eryksun, gaborjbernat, paul.moore, steve.dower, tim.golden, zach.ware
Date 2020-10-12.14:14:48
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1602512088.16.0.251528994177.issue42013@roundup.psfhosted.org>
In-reply-to
Content
This issue is partly due to bpo-8901, which changed the behavior of the -E and -I command-line options to make them ignore the default PythonPath value in the registry key "Software\Python\PythonCore\X.Y\PythonPath". The change itself is not wrong. It's just exposing an underlying problem.

The `home` path in pyvenv.cfg is from sys._base_executable. In a launcher-based environment that's created from the base installation, sys._base_executable is the real base executable. OTOH, in a symlink-based virtual environment, sys._base_executable is the same as sys.executable. Consequently, if a virtual environment is created from a symlink-based virtual environment, the `home` path in pyvenv.cfg refers to the creating environment instead of the base installation. In this case, with the current implementation, the standard library can only be found by falling back on the default PythonPath in the registry.
History
Date User Action Args
2020-10-12 14:14:48eryksunsetrecipients: + eryksun, paul.moore, tim.golden, zach.ware, steve.dower, gaborjbernat
2020-10-12 14:14:48eryksunsetmessageid: <1602512088.16.0.251528994177.issue42013@roundup.psfhosted.org>
2020-10-12 14:14:48eryksunlinkissue42013 messages
2020-10-12 14:14:48eryksuncreate