Python abstract base classes and multiple inheritance [duplicate]
问题 This question already has answers here : python abstractmethod with another baseclass breaks abstract functionality (2 answers) Closed 22 days ago . I am trying to create a python (3.5) class structure where I use abstract methods to indicate which methods should be implemented. The following works as expected: from abc import ABC, abstractmethod class Base(ABC): @abstractmethod def foo(self): pass class Derived(Base, object): # Inheriting from object probably is superfluous (?) pass Derived(