python C-api and thread (Posting On Python-List Prohibited)
aotto1968
aotto1968 at t-online.de
Tue Aug 6 02:01:41 EDT 2024
On 06.08.24 02:32, Lawrence D'Oliveiro wrote:
> On Mon, 5 Aug 2024 23:19:14 +0200, aotto1968 wrote:
>
>> Is it possible to run two completely independent Python interpreters in
>> one process, each using a thread?
>>
>> By independent, I mean that no data is shared between the interpreters
>> and thus the C API can be used without any other "lock/GIL" etc.
>
> Seems like yes
> <https://docs.python.org/3/c-api/init.html#c.Py_NewInterpreterFromConfig>.
→ I think that could be a solution.
More information about the Python-list
mailing list