class_docstr: Poll the state of the Batch Job until it reaches a terminal state; fails if the job fails.
  
  .. seealso::
      For more information on how to use this sensor, take a look at the guide:
      :ref:`howto/sensor:BatchSensor`
  
  :param job_id: Batch job_id to check the state for
  :param aws_conn_id: aws connection to use, defaults to 'aws_default'
  :param region_name: aws region name associated with the client
  :param deferrable: Run sensor in the deferrable mode.
  :param poke_interval: polling period in seconds to check for the status of the job.
  :param max_retries: Number of times to poll for job state before
      returning the current state.
class_docstr_tok: ["Poll","the","state","of","the","Batch","Job","until","it","reaches","a","terminal","state",";","fails","if","the","job","fails",".","..","seealso",":",":","For","more","information","on","how","to","use","this","sensor",",","take","a","look","at","the","guide",":",":","ref",":","`","howto\/sensor",":","BatchSensor","`",":","param","job_id",":","Batch","job_id","to","check","the","state","for",":","param","aws_conn_id",":","aws","connection","to","use",",","defaults","to","'aws_default'",":","param","region_name",":","aws","region","name","associated","with","the","client",":","param","deferrable",":","Run","sensor","in","the","deferrable","mode",".",":","param","poke_interval",":","polling","period","in","seconds","to","check","for","the","status","of","the","job",".",":","param","max_retries",":","Number","of","times","to","poll","for","job","state","before","returning","the","current","state","."]
docstr: Execute when the trigger fires - returns immediately.
  
  Relies on trigger to throw an exception, otherwise it assumes execution was successful.
docstr_tok: ["Execute","when","the","trigger","fires","-","returns","immediately",".","Relies","on","trigger","to","throw","an","exception",",","otherwise","it","assumes","execution","was","successful","."]
code: def execute_complete(
      self, context: Context, event: dict[str, Any]
  ) -> None:
      """
      Execute when the trigger fires - returns immediately.
  
      Relies on trigger to throw an exception, otherwise it assumes execution was successful.
      """
      if event["status"] != "success":
          message = f"Error while running job: {event}"
          # TODO: remove this if-else block when min_airflow_version is set to higher than the version that
          # changed in https://github.com/apache/airflow/pull/33424 is released (2.7.1)
          if self.soft_fail:
              raise AirflowSkipException(message)
          raise AirflowException(message)
      job_id = event["job_id"]
      self.log.info("Batch Job %s complete", job_id)
  
imports: from __future__ import annotations
  from datetime import timedelta
  from functools import cached_property
  from typing import TYPE_CHECKING, Any, Sequence
  from deprecated import deprecated
  from airflow.configuration import conf
  from airflow.exceptions import AirflowException, AirflowProviderDeprecationWarning, AirflowSkipException
  from airflow.providers.amazon.aws.hooks.batch_client import BatchClientHook
  from airflow.providers.amazon.aws.triggers.batch import BatchJobTrigger
  from airflow.sensors.base import BaseSensorOperator
label_desc: Use image node_id 4 for calling the BatchSensor obj's underlying member method code with example usage: obj.execute_complete(context, event) without return types