[issue20614] test.script_helper should copy SYSTEMROOT environment variable for __cleanenv=True

STINNER Victor report at bugs.python.org
Thu Feb 13 11:26:05 CET 2014


New submission from STINNER Victor:

On Windows, if Python is started with an empty environment (no environment variable at all), Python fails with:

"Fatal Python error: Failed to initialize Windows random API (CryptoGen)"

It's the Windows error 0x80090006 which is not displayed in the error message :-(

In fact, it's because Python 3 cannot be started without SYSTEMROOT environment variable. Otherwise, CryptAcquireContext() is unable to find some DLL.

IMO the script_helper should be fixed to copy the variable.

Recent example of this issue:
http://bugs.python.org/issue20599#msg211111

----------
components: Tests
messages: 211138
nosy: brian.curtin, haypo, serhiy.storchaka, tim.golden
priority: normal
severity: normal
status: open
title: test.script_helper should copy SYSTEMROOT environment variable for __cleanenv=True
versions: Python 3.3, Python 3.4, Python 3.5

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue20614>
_______________________________________


More information about the Python-bugs-list mailing list