[issue39395] The os module should unset() environment variable at exit

STINNER Victor report at bugs.python.org
Wed Jan 22 21:11:25 EST 2020


STINNER Victor <vstinner at python.org> added the comment:

Clearing environment variables at exit has a drawback: it changes the behavior in code executed after Python finalization (Py_FinalizeEx() call). It may cause regression.

So I proposed PR 18135 to fix this issue differently: on non-Windows platforms, Python now requires setenv() to build. This PR has no backward compatibility issue: it doesn't unset environment variables at exit.

----------

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


More information about the Python-bugs-list mailing list