[issue20503] super behaviour and abstract base classes (either implementation or documentation/error message is wrong)
Raymond Hettinger
report at bugs.python.org
Sat Feb 27 19:10:50 EST 2021
Raymond Hettinger <raymond.hettinger at gmail.com> added the comment:
This is a bit out of date. The isinstance() docs now specify that the predicate tests for direct, indirect, and virtual inheritance. Likewise, the super() docs already specify that only the __mro__ is searched. So those docs are already precise.
Am thinking of adding a FAQ entry about when direct inheritance is required and include the OP's example. FWIW, this isn't really about super(). It affects any attribute lookup or any other property of inheritance. A true result from instance() doesn't imply that actual inheritance has occurred.
----------
assignee: docs at python -> rhettinger
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue20503>
_______________________________________
More information about the Python-bugs-list
mailing list