#
#
from __future__ import annotations
import datetime
from traceback import format_exception
from typing import Any, Iterable
from sqlalchemy import Column, Integer, String, func, or_
from sqlalchemy.orm import joinedload, relationship
from airflow.models.base import Base
from airflow.models.taskinstance import TaskInstance
from airflow.triggers.base import BaseTrigger
from airflow.utils import timezone
from airflow.utils.retries import run_with_db_retries
from airflow.utils.session import provide_session
from airflow.utils.sqlalchemy import ExtendedJSON, UtcDateTime, with_row_locks
from airflow.utils.state import State
class Trigger(Base):