[issue35266] Add _PyPreConfig and rework _PyCoreConfig and _PyMainInterpreterConfig

2018-12-17 Thread STINNER Victor
STINNER Victor added the comment: When I looked again at this issue, I'm not sure how what should be done, what is the proper design, what should stay after Python initialization, etc. I prefer to abandon this change and maybe retry to write it later. I have a more advanced version in this

[issue35266] Add _PyPreConfig and rework _PyCoreConfig and _PyMainInterpreterConfig

2018-11-22 Thread STINNER Victor
STINNER Victor added the comment: Hum, my split is incomplete. From a high level point of view, the initialization should be done in these steps: 1) select memory allocator, config made of C char* (bytes) and int types 2) select encodings, add wchar_t* (Unicode) strings to the config 3)

[issue35266] Add _PyPreConfig and rework _PyCoreConfig and _PyMainInterpreterConfig

2018-11-22 Thread Nick Coghlan
Nick Coghlan added the comment: I didn't know what was possible when I wrote PEP 432 either - instead, I wrote down an initial concept for what I *wanted*, and then started exploring the code to find out the barriers to achieving that. We know enough now to know that original design concept

[issue35266] Add _PyPreConfig and rework _PyCoreConfig and _PyMainInterpreterConfig

2018-11-18 Thread STINNER Victor
STINNER Victor added the comment: > I like where you're going with this, but would be willing to write an update > to PEP 432 to sketch out in advance what you now think the end state is going > to look like? Sadly, I'm unable to design in advance what will be the final state. Python

[issue35266] Add _PyPreConfig and rework _PyCoreConfig and _PyMainInterpreterConfig

2018-11-18 Thread Nick Coghlan
Nick Coghlan added the comment: I like where you're going with this, but would be willing to write an update to PEP 432 to sketch out in advance what you now think the end state is going to look like? Merging the general structure of the draft PEP 432 implementation to make it possible to

[issue35266] Add _PyPreConfig and rework _PyCoreConfig and _PyMainInterpreterConfig

2018-11-16 Thread STINNER Victor
New submission from STINNER Victor : The C code of Python initialization uses _PyCoreConfig and _PyMainInterpreterConfig which co-exist and more or less redundant. For example, both structures have "argv": wchar_** for _PyCoreConfig, PyObject* (list of str) for _PyMainInterpreterConfig. I

[issue35266] Add _PyPreConfig and rework _PyCoreConfig and _PyMainInterpreterConfig

2018-11-16 Thread STINNER Victor
Change by STINNER Victor : -- keywords: +patch pull_requests: +9823 stage: -> patch review ___ Python tracker ___ ___