[issue42252] Embeddable Python indicates that it uses PYTHONPATH

Tom Kent report at bugs.python.org
Tue Nov 3 12:08:50 EST 2020


Tom Kent <tom at teeks99.com> added the comment:

I'm not sure I agree with that. One possible use-case is to package it along with another program to use the interpreter. In this case they could use the other program's native language features (e.g. .Net's Process.Start(), Win32 API's CreateProcess(), Even Python's subprocess but why?, etc) to run `python.exe myscript.py`. 

In this case, the user may assume that adding something to the `PYTHONPATH` env variable, as most of the launching methods allow, would take hold. When this fails, the first attempt at debugging would be to try it interactively with the same command, then promptly look at python --help when that fails. 

Maybe a better question is why should the embeddable distribution's python.exe ignore env variables? Wouldn't it make more sense to depend on the user to add a `-E` if that is what they desire?

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue42252>
_______________________________________


More information about the Python-bugs-list mailing list