https://github.com/apache/airflow/blob/main/airflow/cli/commands/task_command.py#L145
self, exception: BaseException, task: BaseOperator | None = None
    ) -> tuple[str, str, str]:
        """
        Get the email subject content for exceptions.
        :param exception: the exception sent in the email
        :param task:
        """
        return _get_email_subject_content(task_instance=self, exception=exception, task=task)
    def email_alert(self, exception, task: BaseOperator) -> None:
        """
        Send alert email with exception information.
        :param exception: the exception
        :param task: task related to the exception
        """
        _email_alert(task_instance=self, exception=exception, task=task)
    def set_duration(self) -> None:
        """Set task instance duration."""
        _set_duration(task_instance=self)
    @provide_session
    def xcom_push(
        self,
        key: str,
        value: Any,
        execution_date: datetime | None = None,
        session: Session = NEW_SESSION,