| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
Add support for disabling the use of `posix_spawn` via a variable in the process environment. While it was previously possible to toggle this by modifying the value of `subprocess._USE_POSIX_SPAWN`, this required either patching CPython or modifying it within the interpreter instance which is not always possible, such as when running applications or scripts not under a user's control. Signed-off-by: Vincent Fazio <vfazio@gmail.com>
vfazio@Zephyrus:~/development/cpython$ _PYTHON_SUBPROCESS_USE_POSIX_SPAWN="0" ./python -c "import subprocess; print(subprocess._USE_POSIX_SPAWN)" False vfazio@Zephyrus:~/development/cpython$ _PYTHON_SUBPROCESS_USE_POSIX_SPAWN=0 ./python -c "import subprocess; print(subprocess._USE_POSIX_SPAWN)" False vfazio@Zephyrus:~/development/cpython$ _PYTHON_SUBPROCESS_USE_POSIX_SPAWN=1 ./python -c "import subprocess; print(subprocess._USE_POSIX_SPAWN)" True vfazio@Zephyrus:~/development/cpython$ _PYTHON_SUBPROCESS_USE_POSIX_SPAWN="" ./python -c "import subprocess; print(subprocess._USE_POSIX_SPAWN)" True @gpshead per our discussion in #129204 (comment) |
Sorry, something went wrong.
…nob (pythonGH-132184) * Add _PYTHON_SUBPROCESS_USE_POSIX_SPAWN environment knob Add support for disabling the use of `posix_spawn` via a variable in the process environment. While it was previously possible to toggle this by modifying the value of `subprocess._USE_POSIX_SPAWN`, this required either patching CPython or modifying it within the interpreter instance which is not always possible, such as when running applications or scripts not under a user's control. Signed-off-by: Vincent Fazio <vfazio@gmail.com> * fixup NEWS entry --------- (cherry picked from commit 4c5dcc6) Co-authored-by: Vincent Fazio <vfazio@gmail.com> Signed-off-by: Vincent Fazio <vfazio@gmail.com>
|
GH-132191 is a backport of this pull request to the 3.13 branch. |
Sorry, something went wrong.
…knob (GH-132184) (#132191) gh-129204: Add _PYTHON_SUBPROCESS_USE_POSIX_SPAWN environment knob (GH-132184) * Add _PYTHON_SUBPROCESS_USE_POSIX_SPAWN environment knob Add support for disabling the use of `posix_spawn` via a variable in the process environment. While it was previously possible to toggle this by modifying the value of `subprocess._USE_POSIX_SPAWN`, this required either patching CPython or modifying it within the interpreter instance which is not always possible, such as when running applications or scripts not under a user's control. * fixup NEWS entry --------- (cherry picked from commit 4c5dcc6) Signed-off-by: Vincent Fazio <vfazio@gmail.com> Co-authored-by: Vincent Fazio <vfazio@gmail.com>
| Back | FazBrowse Home | New Git URL |
Add support for disabling the use of posix_spawn via a variable in the process environment.
While it was previously possible to toggle this by modifying the value of subprocess._USE_POSIX_SPAWN, this required either patching CPython or modifying it within the interpreter instance which is not always possible, such as when running applications or scripts not under a user's control.