You could build a subclass, and decorate methods of the subclass. That way you do not modify the original class which can be expected from a decorator:
def cdebug(cls):
class wrapper(cls):
pass
for name, method in inspect.getmembers(cls, inspect.isfunction):
# this one will not decorate special methods
if not (name.startswith('__') and name.endswith('__')):
setattr(wrapper,name, _debug(getattr(cls, name)))
return wrapper
CLICK HERE to find out more related problems solutions.