try:
            self.delete_deployment(namespace, application_session)
        except ApiException as e:
            if e.status == 404:
                self.logger.warning('Deployment not found, assuming it is already deleted')