code: def test_partial_logging_failed():
      run_id = "test_run_id"
      run_data = RunData(throw_exception_on_batch_number=[3, 4])
  
      async_logging_queue = AsyncLoggingQueue(
          run_data.consume_queue_data
      )
      async_logging_queue.activate()
  
      metrics_sent = []
      tags_sent = []
      params_sent = []
  
      run_operations = []
      batch_id = 1
      for params, tags, metrics in _get_run_data():
          if batch_id in [3, 4]:
              with pytest.raises(
                  MlflowException, match="Failed to log run data"
              ):
                  async_logging_queue.log_batch_async(
                      run_id=run_id,
                      metrics=metrics,
                      tags=tags,
                      params=params,
                  ).wait()
          else:
              run_operations.append(
                  async_logging_queue.log_batch_async(
                      run_id=run_id,
                      metrics=metrics,
                      tags=tags,
                      params=params,
                  )
              )
              metrics_sent += metrics
              tags_sent += tags
              params_sent += params
  
          batch_id += 1
  
      for run_operation in run_operations:
          run_operation.wait()
  
      _assert_sent_received_data(
          metrics_sent,
          params_sent,
          tags_sent,
          run_data.received_metrics,
          run_data.received_params,
          run_data.received_tags,
      )
  
imports: import io
  import pickle
  import random
  import threading
  import time
  import uuid
  import pytest
  from mlflow import MlflowException
  from mlflow.entities.metric import Metric
  from mlflow.entities.param import Param
  from mlflow.entities.run_tag import RunTag
  from mlflow.utils.async_logging.async_logging_queue import AsyncLoggingQueue
label_desc: Use image node_id 3 for calling a global function with example usage: test_partial_logging_failed() without return types