[Python-checkins] bpo-39439: Fix multiprocessing spawn path in a venv on Windows (GH-18158)
Steve Dower
webhook-mailer at python.org
Tue Jan 28 05:34:27 EST 2020
https://github.com/python/cpython/commit/0be3246d4f9c8eddcd55491901d95b09fe163f15
commit: 0be3246d4f9c8eddcd55491901d95b09fe163f15
branch: master
author: Adam Meily <ameily at users.noreply.github.com>
committer: Steve Dower <steve.dower at python.org>
date: 2020-01-28T21:34:23+11:00
summary:
bpo-39439: Fix multiprocessing spawn path in a venv on Windows (GH-18158)
files:
A Misc/NEWS.d/next/Windows/2020-01-24-03-15-05.bpo-39439.sFxGfR.rst
M Lib/multiprocessing/spawn.py
diff --git a/Lib/multiprocessing/spawn.py b/Lib/multiprocessing/spawn.py
index 075f3455478b5..7cc129e261076 100644
--- a/Lib/multiprocessing/spawn.py
+++ b/Lib/multiprocessing/spawn.py
@@ -36,7 +36,7 @@
if WINSERVICE:
_python_exe = os.path.join(sys.exec_prefix, 'python.exe')
else:
- _python_exe = sys._base_executable
+ _python_exe = sys.executable
def set_executable(exe):
global _python_exe
diff --git a/Misc/NEWS.d/next/Windows/2020-01-24-03-15-05.bpo-39439.sFxGfR.rst b/Misc/NEWS.d/next/Windows/2020-01-24-03-15-05.bpo-39439.sFxGfR.rst
new file mode 100644
index 0000000000000..d677c4c3e02d5
--- /dev/null
+++ b/Misc/NEWS.d/next/Windows/2020-01-24-03-15-05.bpo-39439.sFxGfR.rst
@@ -0,0 +1 @@
+Honor the Python path when a virtualenv is active on Windows.
\ No newline at end of file
More information about the Python-checkins
mailing list