I want to unwrap a classmethod into an instance method. Is it possible to do it?
class A:
@classmethod
def my_classmethod(cls, *args, **kwargs):
...
class B:
# in this case my_uwrapped_method is still a classmethod
my_uwrapped_method = A.my_classmethod
Is it possible to unwrap the my_classmethod into a instance method with some python magic, meanwhile retaining the same code from the original method?
I found this way of unwrapping a staticmethod here: "Unwraping" and wrapping again @staticmethod in meta class
But the same does not work with classmethods, unfortunately.