code: def test_poll_job_status_hit_api_throttle(self, caplog):
      self.client_mock.describe_jobs.side_effect = (
          botocore.exceptions.ClientError(
              error_response={
                  "Error": {"Code": "TooManyRequestsException"}
              },
              operation_name="get job description",
          )
      )
      with pytest.raises(AirflowException) as ctx:
          with caplog.at_level(level=logging.getLevelName("WARNING")):
              self.batch_client.poll_for_job_complete(JOB_ID)
      log_record = caplog.records[0]
      assert (
          "Ignored TooManyRequestsException error" in log_record.message
      )
  
      msg = f"AWS Batch job ({JOB_ID}) description error"
      assert msg in str(ctx.value)
      # It should retry when this client error occurs
      self.client_mock.describe_jobs.assert_called_with(jobs=[JOB_ID])
      assert (
          self.client_mock.describe_jobs.call_count
          == self.STATUS_RETRIES
      )
  
imports: from __future__ import annotations
  import logging
  import time
  from unittest import mock
  import botocore.exceptions
  import pytest
  from airflow.exceptions import AirflowException
  from airflow.providers.amazon.aws.hooks.batch_client import BatchClientHook
  from airflow.providers.amazon.aws.utils.task_log_fetcher import AwsTaskLogFetcher
label_desc: Use image node_id 9 for calling the TestBatchClient obj's underlying member method code with example usage: obj.test_poll_job_status_hit_api_throttle(caplog) without return types