It seems like `name` is never stored. Are you missing a `self.name = name or func.__name__`.