Closed
Description
When we invoke pip, we use -I
to avoid interference from other variables. However, this also means that we ignore legitimate user preferences that ought to be retained. We probably want PYTHONDONTWRITEBYTECODE
, PYTHONUTF8
, PYTHONIOENCODING
, PYTHONMALLOC
, PYTHONCOERCECLOCALE
, PYTHONPYCACHEPREFIX
at least, and maybe more (I just went through the help output of 3.10).
Interestingly, we don't use isolated mode later on when we upgrade the packages, so maybe we don't need it at all? Or perhaps we should be in some middle ground where we override PYTHONPATH
and PYTHONHOME
to point at the venv/be empty but leave everything else in place?
Ping @vsajip
(Discovered in a system where attempting to write .pyc files would break.)