Python: disable user site-packages in setup hook

Wrappers already included `PYTHONNOUSERSITE=1`, but now this env var is
also set in the Python setup hook. This improves purity in case of
non-sandboxes builds and nix-shell.
This commit is contained in:
Frederik Rietdijk 2017-12-30 15:33:59 +01:00
parent d170941f6e
commit 0808b959ae

View File

@ -19,3 +19,6 @@ envHooks+=(addPythonPath)
export DETERMINISTIC_BUILD=1;
# Determinism: We fix the hashes of str, bytes and datetime objects.
export PYTHONHASHSEED=0;
# Determinism. Whenever Python is included, it should not check user site-packages.
# This option is only relevant when the sandbox is disabled.
export PYTHONNOUSERSITE=1;