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 ztane
Recipients Romuald, xiang.zhang, ztane
Date 2016-07-18.08:51:34
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1468831894.85.0.234383584557.issue27558@psf.upfronthosting.co.za>
In-reply-to
Content
Reproducible on Python 3.6a4ish on Ubuntu. I believe this needs forking multiprocessing.

do_raise is called with 2 NULLs as arguments, it should raise

    PyErr_SetString(PyExc_RuntimeError,
                            "No active exception to reraise");

What happens is that PyThreadState is initialized to *all* NULL pointers on the new thread on multiprocessing, however `type` is expected to point to `Py_None` when no exception has been raised:

        PyThreadState *tstate = PyThreadState_GET();
        PyObject *tb;
        type = tstate->exc_type;
        value = tstate->exc_value;
        tb = tstate->exc_traceback;
        if (type == Py_None) {
            PyErr_SetString(PyExc_RuntimeError,
                            "No active exception to reraise");
            return 0;
        }

I am not sure where the thread state should have been initialized though
History
Date User Action Args
2016-07-18 08:51:34ztanesetrecipients: + ztane, Romuald, xiang.zhang
2016-07-18 08:51:34ztanesetmessageid: <1468831894.85.0.234383584557.issue27558@psf.upfronthosting.co.za>
2016-07-18 08:51:34ztanelinkissue27558 messages
2016-07-18 08:51:34ztanecreate