Re: [Pyobjc-dev] Crash with pyobjc 1.1 when i call recursively PyRun_SimpleString
Brought to you by:
ronaldoussoren
From: Jack J. <Jac...@cw...> - 2004-07-24 20:34:19
|
On 24 Jul 2004, at 20:30, Ronald Oussoren wrote: > PyObjC gives up the global interpreter lock just before calling > Objective-C code (when using Python 2.3). This was introduced in > version 1.1. > > You can use the PyGILState_Ensure API to make sure you can call back > into Python (http://www.python.org/peps/pep-0311.html). I was going to post this in the other thread on calling Python from ObjC, but this is another example of what I think is the same problem: there are some rules for going from ObjC to Python that are not exactly clear. Should we create an ObjC class "Python" or "PythonInterpreter" that handles the various common cases of things people would want to do with the Python interpreter, such as PyRun_SimpleString? -- Jack Jansen, <Jac...@cw...>, http://www.cwi.nl/~jack If I can't dance I don't want to be part of your revolution -- Emma Goldman |