def on_cleanup_error(function, path, excinfo):
                click.secho("warning: failed to remove file or directory: {}\n"
                            "please delete it manually.".format(path),
                            fg="red")
def is_resource_deleted(self, id):
        try:
            self.get_snapshot(id)
        except exceptions.NotFound:
            return True
        return False