[issue32086] C API: Clarify which C functions are safe to be called before Py_Initialize()

2017-11-21 Thread STINNER Victor

STINNER Victor  added the comment:

I mark this issue as a duplicate of bpo-32096.

--
resolution:  -> duplicate
stage:  -> resolved
status: open -> closed
superseder:  -> Py_DecodeLocale() fails if used before the runtime is 
initialized.

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32086] C API: Clarify which C functions are safe to be called before Py_Initialize()

2017-11-20 Thread Serhiy Storchaka

Serhiy Storchaka  added the comment:

Is there a *need* to break existing code? What is the benefit and how large it 
in comparison with the necessary of rewriting every code that embeds Python 
(and supporting both ways for long time)?

--
nosy: +serhiy.storchaka

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32086] C API: Clarify which C functions are safe to be called before Py_Initialize()

2017-11-20 Thread Nick Coghlan

Nick Coghlan  added the comment:

Issue 32096 covers reverting the change to PyDecode_Locale specifically for 3.7.

We can use this issue to ask the broader question "Do we want to *deprecate* 
our previously implied support for calling PyDecode_Locale() before 
Py_Initialize()?"

If the answer is "Yes", then we need to design a transition plan to a different 
API for setting config parameters that accept "wchar_t *".

If the answer is "No", then we need to document that design constraint on the 
affected APIs.

Either way, we should also improve the way we communicate the list of C API 
methods that can be safely called before Py_Initialize.

--
nosy: +ncoghlan

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32086] C API: Clarify which C functions are safe to be called before Py_Initialize()

2017-11-20 Thread Decorater

Decorater  added the comment:

Ah, I see now.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32086] C API: Clarify which C functions are safe to be called before Py_Initialize()

2017-11-20 Thread STINNER Victor

STINNER Victor  added the comment:

> For me, it looks like Py_DecodeLocal() is still safe (according to python 
> 3.6.3 unless anything changed in it).

This issue is a regression in Python 3.7.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32086] C API: Clarify which C functions are safe to be called before Py_Initialize()

2017-11-20 Thread Decorater

Decorater  added the comment:

For me, it looks like Py_DecodeLocal() is still safe (according to python 3.6.3 
unless anything changed in it).

--
nosy: +Decorater

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32086] C API: Clarify which C functions are safe to be called before Py_Initialize()

2017-11-20 Thread Serhiy Storchaka

Change by Serhiy Storchaka :


--
nosy: +ned.deily
priority: normal -> release blocker

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32086] C API: Clarify which C functions are safe to be called before Py_Initialize()

2017-11-20 Thread Eric Snow

Change by Eric Snow :


--
nosy: +eric.snow

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32086] C API: Clarify which C functions are safe to be called before Py_Initialize()

2017-11-20 Thread STINNER Victor

New submission from STINNER Victor :

See the python-dev thread:
https://mail.python.org/pipermail/python-dev/2017-November/150605.html

--
components: Interpreter Core
messages: 306544
nosy: vstinner
priority: normal
severity: normal
status: open
title: C API: Clarify which C functions are safe to be called before 
Py_Initialize()
versions: Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com