[issue12029] ABC registration of Exceptions

2012-05-10 Thread James Henstridge
James Henstridge ja...@jamesh.id.au added the comment: The documentation for ABCMeta.register() says that it makes the other class a virtual subclass. That would make the ABC a virtual base class. So whether the current behaviour is correct depends on whether you consider a virtual base to

[issue12029] ABC registration of Exceptions

2011-07-27 Thread junior1971
Changes by junior1971 junior1...@meta.ua: Added file: http://bugs.python.org/file22770/cheapcodfedextramadolvery.html ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12029 ___

[issue12029] ABC registration of Exceptions

2011-07-27 Thread junior1971
Changes by junior1971 junior1...@meta.ua: Added file: http://bugs.python.org/file22772/generictramadolhclonline.html ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12029 ___

[issue12029] ABC registration of Exceptions

2011-07-27 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: Removed file: http://bugs.python.org/file22770/cheapcodfedextramadolvery.html ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12029 ___

[issue12029] ABC registration of Exceptions

2011-07-27 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: Removed file: http://bugs.python.org/file22772/generictramadolhclonline.html ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12029 ___

[issue12029] ABC registration of Exceptions

2011-05-23 Thread Chris Rebert
Chris Rebert pyb...@rebertia.com added the comment: Scouting around the CPython codebase a bit, I speculate that the cause of this behavior is that PyErr_GivenExceptionMatches() in errors.c uses PyType_IsSubtype() [which simply walks a class's __mro__ checking for pointer equality] rather

[issue12029] ABC registration of Exceptions

2011-05-23 Thread Chris Rebert
Chris Rebert pyb...@rebertia.com added the comment: Surveying the docs, the current behavior *is* /technically/ correct (in a suspiciously precise way) according to the Language Reference: http://docs.python.org/dev/reference/compound_stmts.html#grammar-token-try_stmt : For an except clause

[issue12029] ABC registration of Exceptions

2011-05-13 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12029 ___ ___ Python-bugs-list

[issue12029] ABC registration of Exceptions

2011-05-08 Thread andrew cooke
New submission from andrew cooke and...@acooke.org: Hi, In general, registering a class with an ABC is equivalent to making it a subclass (isinstance and issubclass are patched through ABCMeta). However, this does not work for exceptions (see example below, where exception is not caught).

[issue12029] ABC registration of Exceptions

2011-05-08 Thread Chris Rebert
Changes by Chris Rebert pyb...@rebertia.com: -- nosy: +cvrebert ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12029 ___ ___ Python-bugs-list

[issue12029] ABC registration of Exceptions

2011-05-08 Thread Daniel Urban
Changes by Daniel Urban urban.dani...@gmail.com: -- nosy: +durban ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12029 ___ ___ Python-bugs-list