(domain, new_plan_version)
Any active automatic case update rules should be deactivated.
Any active automatic case update rules should be deactivated.
Any active automatic case update rules should be deactivated .
def response_data_cleanup(domain, new_plan_version):
        """
        Any active automatic case update rules should be deactivated.
        """
        try:
            AutomaticUpdateRule.by_domain(
                domain.name,
                AutomaticUpdateRule.WORKFLOW_CASE_UPDATE,
            ).update(active=False)
            AutomaticUpdateRule.clear_caches(domain.name, AutomaticUpdateRule.WORKFLOW_CASE_UPDATE)
            return True
        except Exception:
            log_accounting_error(
                "Failed to deactivate automatic update rules "
                "for domain %s." % domain.name
            )
            return False
def response_data_cleanup ( domain , new_plan_version ) : try : AutomaticUpdateRule . by_domain ( domain . name , AutomaticUpdateRule . WORKFLOW_CASE_UPDATE , ) . update ( active = False ) AutomaticUpdateRule . clear_caches ( domain . name , AutomaticUpdateRule . WORKFLOW_CASE_UPDATE ) return True except Exception : log_accounting_error ( "Failed to deactivate automatic update rules " "for domain %s." % domain . name ) return False