def foo(kls, param):
    print('A.foo called, param is ' + param)

def foo_wrapper(wrapped_func):
    wrapped_func = wrapped_func.__func__

def _w(*args, **kwargs):
    print('<foo_wrap>')
wrapped_func(*args, **kwargs)
print('</foo_wrap>')
return classmethod(_w)
A.foo = foo_wrapper(A.foo)
A.foo('bar')
How to wrap (monkey patch) @classmethod