Terry J. Reedy <tjre...@udel.edu> added the comment:

https://docs.python.org/3/reference/datamodel.html#customizing-instance-and-subclass-checks
says
"Note that these methods are looked up on the type (metaclass) of a class. They 
cannot be defined as class methods in the actual class. This is consistent with 
the lookup of special methods that are called on instances, only in this case 
the instance is itself a class."

IE, your first example is documented as wrong.  Your second example, which 
works, follows the example in
https://docs.python.org/3/reference/datamodel.html#customizing-instance-and-subclass-checks

----------
nosy: +terry.reedy
resolution:  -> not a bug
stage:  -> resolved
status: open -> closed
versions: +Python 3.8

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue33417>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to