We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 42d6008 commit 13633f5Copy full SHA for 13633f5
py/tools/py/src/activate.tmpl
@@ -61,6 +61,12 @@ deactivate nondestructive
61
VIRTUAL_ENV="$(dirname "$(dirname "${BASH_SOURCE}")")"
62
export VIRTUAL_ENV
63
64
+# HACK: (Ab)use the MacOS $PYTHONEXECUTABLE to record the `.runfiles`-relative
65
+# interpreter path. This helps us avoid issues with the interpreter's path being
66
+# `realpath`-ed in such a way that it escapes the `.runfiles` tree.
67
+PYTHONEXECUTABLE="${VIRTUAL_ENV}/bin/python"
68
+export PYTHONEXECUTABLE
69
+
70
# unset PYTHONHOME if set
71
# this will fail if PYTHONHOME is set to the empty string (which is bad anyway)
72
# could use `if (set -u; : $PYTHONHOME) ;` in bash.
0 commit comments