commit | 3d5a41168215bd25f45dfac21ccf09d6184c1a4b | [log] [tgz] |
---|---|---|
author | Joe Ethier <jethier@google.com> | Thu Apr 22 11:39:02 2021 -0700 |
committer | CQ Bot Account <pigweed-scoped@luci-project-accounts.iam.gserviceaccount.com> | Thu Apr 22 19:18:19 2021 +0000 |
tree | 746256ecf7f522ace92634f0498e8093a562dad4 | |
parent | 08dc120595cbd86390f86cc15119045324a32be0 [diff] |
pw_env_setup: Clear __PYENV_LAUNCHER__ pre- GN run On some MacOS Python distributions, the presence of a __PYENV_LAUNCHER__ env variable can cause pip installs to go into the wrong Python environment (in addition to messing up venv creation). Change-Id: Ifd3a45a0294910c6288451ce4574f4344f942124 Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/42360 Reviewed-by: Rob Mohr <mohrr@google.com> Pigweed-Auto-Submit: Joe Ethier <jethier@google.com> Commit-Queue: Auto-Submit <auto-submit@pigweed.google.com.iam.gserviceaccount.com>
diff --git a/pw_env_setup/py/pw_env_setup/virtualenv_setup/install.py b/pw_env_setup/py/pw_env_setup/virtualenv_setup/install.py index 8a2b699..5f576aa 100644 --- a/pw_env_setup/py/pw_env_setup/virtualenv_setup/install.py +++ b/pw_env_setup/py/pw_env_setup/virtualenv_setup/install.py
@@ -254,6 +254,7 @@ env.set('VIRTUAL_ENV', venv_path) env.prepend('PATH', venv_bin) env.clear('PYTHONHOME') + env.clear('__PYVENV_LAUNCHER__') with env(): for gn_target in gn_targets: install_packages(gn_target)