class_docstr: Hook for Azure Batch APIs.
  
  :param azure_batch_conn_id: :ref:`Azure Batch connection id<howto/connection:azure_batch>`
      of a service principal which will be used to start the container instance.
class_docstr_tok: ["Hook","for","Azure","Batch","APIs",".",":","param","azure_batch_conn_id",":",":","ref",":","`","Azure","Batch","connection","id","<","howto\/connection",":","azure_batch",">","`","of","a","service","principal","which","will","be","used","to","start","the","container","instance","."]
docstr: Add a single task to given job if it doesn't exist.
  
  :param job_id: A string that identifies the given job
  :param task: The task to add
docstr_tok: ["Add","a","single","task","to","given","job","if","it","does","n't","exist",".",":","param","job_id",":","A","string","that","identifies","the","given","job",":","param","task",":","The","task","to","add"]
code: def add_single_task_to_job(
      self, job_id: str, task: TaskAddParameter
  ) -> None:
      """
      Add a single task to given job if it doesn't exist.
  
      :param job_id: A string that identifies the given job
      :param task: The task to add
      """
      try:
          self.connection.task.add(job_id=job_id, task=task)
      except batch_models.BatchErrorException as err:
          if not err.error or err.error.code != "TaskExists":
              raise
          else:
              self.log.info("Task %s already exists", task.id)
  
imports: from __future__ import annotations
  import time
  from datetime import timedelta
  from functools import cached_property
  from typing import TYPE_CHECKING, Any
  from azure.batch import BatchServiceClient, batch_auth, models
  from airflow.exceptions import AirflowException
  from airflow.hooks.base import BaseHook
  from airflow.providers.microsoft.azure.utils import AzureIdentityCredentialAdapter, add_managed_identity_connection_widgets, get_field
  from airflow.utils import timezone
label_desc: Use image node_id 14 for calling the AzureBatchHook obj's underlying member method code with example usage: obj.add_single_task_to_job(job_id, task) without return types