ephraimbuddy commented on code in PR #40846: URL: https://github.com/apache/airflow/pull/40846#discussion_r1682396100
########## airflow/models/taskinstancehistory.py: ########## @@ -44,8 +64,76 @@ class TaskInstanceHistory(Base): dag_id = Column(StringID(), nullable=False) run_id = Column(StringID(), nullable=False) map_index = Column(Integer, nullable=False, server_default=text("-1")) - try_number = Column(Integer, nullable=False) - # The rest of the columns are kept in sync with TaskInstance, added at the bottom of this file + start_date = Column(UtcDateTime) + end_date = Column(UtcDateTime) + duration = Column(Float) + state = Column(String(20)) + try_number = Column(Integer, default=0) + max_tries = Column(Integer, server_default=text("-1")) + hostname = Column(String(1000)) + unixname = Column(String(1000)) + job_id = Column(Integer) + pool = Column(String(256), nullable=False) + pool_slots = Column(Integer, default=1, nullable=False) + queue = Column(String(256)) + priority_weight = Column(Integer) + operator = Column(String(1000)) + custom_operator_name = Column(String(1000)) + queued_dttm = Column(UtcDateTime) + queued_by_job_id = Column(Integer) + pid = Column(Integer) + executor = Column(String(1000)) + executor_config = Column(ExecutorConfigType(pickler=dill)) + updated_at = Column(UtcDateTime, default=timezone.utcnow, onupdate=timezone.utcnow) + rendered_map_index = Column(String(250)) + + external_executor_id = Column(StringID()) + trigger_id = Column(Integer) + trigger_timeout = Column(DateTime) + next_method = Column(String(1000)) + next_kwargs = Column(MutableDict.as_mutable(ExtendedJSON)) + + _task_display_property_value = Column("task_display_name", String(2000), nullable=True) + + dag_run = relationship( Review Comment: Hi @jedcunningham, I would like to know if you are now in agreement about the relationships being declared in TI history with viewonly set. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@airflow.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org