Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
bpo-33612: Remove PyThreadState_Clear() assertion (#7069)
bpo-25612, bpo-33612: Remove an assertion from PyThreadState_Clear()
which failed at Python shutdown or on fork if a thread was running a
generator.
  • Loading branch information
vstinner committed May 23, 2018
1 parent 825aab9 commit b6dccf5
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion Python/pystate.c
Expand Up @@ -586,7 +586,6 @@ PyThreadState_Clear(PyThreadState *tstate)
Py_CLEAR(tstate->exc_state.exc_traceback);

/* The stack of exception states should contain just this thread. */
assert(tstate->exc_info->previous_item == NULL);
if (Py_VerboseFlag && tstate->exc_info != &tstate->exc_state) {
fprintf(stderr,
"PyThreadState_Clear: warning: thread still has a generator\n");
Expand Down

0 comments on commit b6dccf5

Please sign in to comment.