[issue42902] a python embedded program may load "C:\Lib\os.py" on windows system
STINNER Victor
report at bugs.python.org
Tue Jan 12 05:24:58 EST 2021
STINNER Victor <vstinner at python.org> added the comment:
> I thought that *all* versions of Python located the standard library by searching for os.py...
The current implementation of the Python Path Configuration can be found in:
* Windows: PC/getpathp.c
* Unix: Modules/getpath.c
It should be skipped if Py_SetPath() is used, but I recommend to only rely on PyConfig and its documentation:
https://docs.python.org/dev/c-api/init_config.html#python-path-configuration
If the documentation is wrong, it must be fixed ;-)
I still don't understand if the issue involves Py_SetPath() or not.
----------
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue42902>
_______________________________________
More information about the Python-bugs-list
mailing list