threads

Ayelet Snir ayelet at kagoor.com
Wed Aug 29 13:44:27 EDT 2001


Hello,

We are new users of Python, and we though you might be able to help us in a
problem we're dealing:

We have a project, written in Python and also C. Notice that we call to the
C part from Python, using SWIG.
In this project, we created 2 threads in the Python part:
While moving from C to Python, we use: PyEval_AcquireLock, and swap the
thread state. (On the other direction, we use: PyEval_ReleaseLock and swap
the state back.)
Till here, everything worked great.
We tried to start another new thread, using the method start_new. We got the
next message:
Fatal Python error: PyEval_AcquireThread : non-NULL old thread state

Thanks,
Ayelet & Michal
Kagoor Networks LTD









More information about the Python-list mailing list