don't use magic methods directly
Try to avoid getting dunder attributes directly. Python provides helper functions for getting of of standard dunder attributes:
type(self)
instead ofself.__class__
inspect.getdoc(cls)
instead ofcls.__doc__
vars(obj)
instead ofobj.__dict__
cls.mro()
instead ofcls.__mro__