While reviewing some code, it has a structure like
class Bar(Foo, object):
Which seems like it could easily be written instead as
class Bar(Foo):
The functionally appears at least the same the simple chain of inheritance for the purpose of determining method resolution, and both Foo and Bar are isinstance() of object in both cases
B → F → o
B → F
↳ o
Is there any practical benefit to a multiple inheritance from object?
Almost certainly, no, it shouldn't have any effect, the MRO is still the same:
So:
Potentially, I suppose, it could have an effect if any code introspects
__bases__:But I highly suspect this is just a typo