]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
[3.7] bpo-34247: Fix Python 3.7 initialization (#8659)
authorVictor Stinner <vstinner@redhat.com>
Sun, 5 Aug 2018 10:31:59 +0000 (12:31 +0200)
committerGitHub <noreply@github.com>
Sun, 5 Aug 2018 10:31:59 +0000 (12:31 +0200)
commit0c90d6f75931da4fec84d06c2efe9dd94bb96b77
treeec34949a2d8b022b854acb0e885552c8fc0dd5ff
parente65ec491fbaa14db61a6559eb269733616b0e7f0
[3.7] bpo-34247: Fix Python 3.7 initialization (#8659)

* -X dev: it is now possible to override the memory allocator using
  PYTHONMALLOC even if the developer mode is enabled.
* Add _Py_InitializeFromConfig()
* Add _Py_Initialize_ReadEnvVars() to set global configuration
  variables from environment variables
* Fix the code to initialize Python: Py_Initialize() now also reads
  environment variables
* _Py_InitializeCore() can now be called twice: the second call
  only replaces the configuration.
* Write unit tests on Py_Initialize() and the different ways to
  configure Python
* The isolated mode now always sets Py_IgnoreEnvironmentFlag and
  Py_NoUserSiteDirectory to 1.
* pymain_read_conf() now saves/restores the configuration
  if the encoding changed
Include/pylifecycle.h
Include/pystate.h
Lib/test/test_cmd_line.py
Lib/test/test_embed.py
Misc/NEWS.d/next/C API/2018-08-05-00-21-38.bpo-34247._Sn92u.rst [new file with mode: 0644]
Misc/NEWS.d/next/Core and Builtins/2018-08-03-21-59-06.bpo-34170.v1h_H2.rst [new file with mode: 0644]
Modules/main.c
Programs/_freeze_importlib.c
Programs/_testembed.c
Python/pylifecycle.c