I have a superclass (defined in a framework). Someone makes a subclass of my parent class using my framework (via pip install). Then they init an object of their class. How can I find out all the args AND values that went into that init?
class Parent(object):
class Child(Parent):
def __init__(self, arg_1, arg_2, some_object):
pass
obj = Child(2, {'some': 'dict'}, MyObject())
Is there a way to look at the object function to see what values it used? (the object is not created by me... so even looking at self.whatever isn't guaranteed to have all values used in that function call).
some_magic(obj.__init__)
# {arg_1: 2, arg_2: {'some': 'dict'}, some_object: MyObject_instance}