This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author dmalcolm
Recipients bquinlan, dmalcolm, lukasz.langa
Date 2010-11-24.16:28:37
SpamBayes Score 1.1474155e-13
Marked as misclassified No
Message-id <>
I'm able to reliably reproduce this on a RHEL 5 box (i386 in this case).

All of the "ProcessPool*" unittest subclasses within Lib/test/ exhibit this hang, each printing out just the name of the first test (so presumably either within the first test method, or in shared setup/teardown).

None of the other subclasses hang.

You need to build with --with-pydebug to see this: the error message is coming from this code in PyThreadState_Swap in Python/pystate.c:

   390  #if defined(Py_DEBUG) && defined(WITH_THREAD)
   391      if (newts) {
   392          /* This can be called from PyEval_RestoreThread(). Similar
   393             to it, we need to ensure errno doesn't change.
   394          */
   395          int err = errno;
   396          PyThreadState *check = PyGILState_GetThisThreadState();
   397          if (check && check->interp == newts->interp && check != newts)
>>>398              Py_FatalError("Invalid thread state for this thread");
   399          errno = err;
   400      }
   401  #endif
Date User Action Args
2010-11-24 16:28:40dmalcolmsetrecipients: + dmalcolm, bquinlan, lukasz.langa
2010-11-24 16:28:40dmalcolmsetmessageid: <>
2010-11-24 16:28:37dmalcolmlinkissue10517 messages
2010-11-24 16:28:37dmalcolmcreate