pub async fn run(self, mut stop_receiver: watch::Receiver<bool>) -> anyhow::Result<()> {
        let exit_on_success = self.exit_on_success;
        let validation = self.validate_commitment_mode();
        tokio::select! {
            result = validation => {
                if exit_on_success || result.is_err() {
                    return result;
                }
                stop_receiver.changed().await.ok();
                Ok(())
            },
            _ = stop_receiver.changed() => Ok(()),
        }
    }
Runs this task. The task will exit on error (and on success if `exit_on_success` is set),
or when a stop request is received.
core/node/commitment_generator/src/validation_task.rs