[issue3611] invalid exception context

Antoine Pitrou report at bugs.python.org
Wed Aug 20 18:49:36 CEST 2008


Antoine Pitrou <pitrou at free.fr> added the comment:

[...]
>
> This exception may comes from PyObject_IsSubclass() which calls
> PyObject_GetAttr(cls, "__subclasscheck__").

If you look at the code for PyObject_IsSubclass(), there is a pair of
PyErr_Fetch / PyErr_Restore calls around PyObject_GetAttr(cls,
"__subclasscheck__"). So this exception should vanish immediately rather than
stay around.

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue3611>
_______________________________________


More information about the Python-bugs-list mailing list