Hi,

the long-standing exception handling crash bug in Py3.0 and later that
prevented Cython from running its test suite on Py3 has finally been fixed.

http://bugs.python.org/issue7173

The patch below lets Cython run safely on the latest Python 3.2 and will
hopefully make it into Python 3.1.2 soon.

Running the test suite on a patched CPython immediately revealed several
Py3 problems in the tests, so please try to build a patched Py3.2 from SVN
HEAD or apply the patch to the 3.1.1 release version, run Cython's test
suite, and try to fix them as you see fit.

Stefan


diff -r 4465a45b8876 Python/ceval.c
--- a/Python/ceval.c    Mon Feb 15 09:35:16 2010 +0100
+++ b/Python/ceval.c    Mon Feb 15 20:51:58 2010 +0100
@@ -1159,7 +1159,7 @@ PyEval_EvalFrameEx(PyFrameObject *f, int
        assert(stack_pointer != NULL);
        f->f_stacktop = NULL;   /* remains NULL unless yield suspends frame */

-       if (f->f_code->co_flags & CO_GENERATOR) {
+       if (!throwflag && (f->f_code->co_flags & CO_GENERATOR)) {
                if (f->f_exc_type != NULL && f->f_exc_type != Py_None) {
                        /* We were in an except handler when we left,
                           restore the exception state which was put aside
_______________________________________________
Cython-dev mailing list
[email protected]
http://codespeak.net/mailman/listinfo/cython-dev

Reply via email to