pub fn validate_checkpoint( history: &[Message], pending: Option<PendingOperation>, ) -> Result<(), StateError>