Author eryksun
Recipients eryksun, miss-islington, paul.moore, pierreglaser, pitrou, steve.dower, tim.golden, zach.ware
Date 2019-10-24.02:15:37
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1571883337.71.0.813489315289.issue38092@roundup.psfhosted.org>
In-reply-to
Content
This should revert to setting `_python_exe = sys.executable` in Lib/multiprocessing/spawn.py. Then the code in Lib/multiprocessing/popen_spawn_win32.py will set __PYVENV_LAUNCHER__ in the spawned process to the virtual environment's sys.executable. Otherwise the worker process has no connection to the virtual environment, other than how sys.path gets manually copied from the parent process. In particular, without setting __PYVENV_LAUNCHER__, sys.executable is not the virtual-environment executable and sys.prefix is not the virtual-environment directory.

Also, the fix for the parameters that are passed to _winapi.CreateProcess needs to be backported to 3.7. Else __PYVENV_LAUNCHER__ won't actually be set in the child.
History
Date User Action Args
2019-10-24 02:15:37eryksunsetrecipients: + eryksun, paul.moore, pitrou, tim.golden, zach.ware, steve.dower, miss-islington, pierreglaser
2019-10-24 02:15:37eryksunsetmessageid: <1571883337.71.0.813489315289.issue38092@roundup.psfhosted.org>
2019-10-24 02:15:37eryksunlinkissue38092 messages
2019-10-24 02:15:37eryksuncreate