def unwrap(func):
    """
        Fully unwrap a wrapped object
    :param func: Function to unwrap
    :return: Unwrapped function
    """
    while hasattr(func, "__wrapped__"):
        func = func.__wrapped__
    return func