I have multiple inheritance layers and I am trying to understand if this could not lead to a performance issue due to the multiple calls. Here is also a small example to illustrate it:
class MySuperClass:
def __init__(self, arg1):
self.arg1 = arg1
class MyFirstSubClass(MySuperClass):
def __init__(self, arg1, arg2):
super().__init__(arg1)
self.arg2 = arg2
class MySecondSubClass(MyFirstSubClass):
def __init__(self, arg1, arg2, arg3):
super().__init__(arg1, arg2)
self.arg3 = arg3
How does Python work here. Are the super calls executed every time the objects are created?