This is an automated email from the ASF dual-hosted git repository.
amoghrajesh pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git
The following commit(s) were added to refs/heads/main by this push:
new 7437b7d5670 Fix potentially misleading comment on task state store
model (#68824)
7437b7d5670 is described below
commit 7437b7d5670a7469564349052ed09f5345b6f161
Author: Amogh Desai <[email protected]>
AuthorDate: Mon Jun 22 14:24:51 2026 +0530
Fix potentially misleading comment on task state store model (#68824)
---
airflow-core/src/airflow/models/task_state_store.py | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/airflow-core/src/airflow/models/task_state_store.py
b/airflow-core/src/airflow/models/task_state_store.py
index be62c1a9ad8..7ca497defe5 100644
--- a/airflow-core/src/airflow/models/task_state_store.py
+++ b/airflow-core/src/airflow/models/task_state_store.py
@@ -50,11 +50,10 @@ class TaskStateStoreModel(Base):
value: Mapped[str] = mapped_column(Text().with_variant(MEDIUMTEXT,
"mysql"), nullable=False)
updated_at: Mapped[datetime] = mapped_column(UtcDateTime,
default=timezone.utcnow, nullable=False)
- # Optional override for early expiry. When set, garbage collection deletes
this row when
- # expires_at < now(), even if updated_at is recent. NULL means no early
expiry —
- # the row is still cleaned up by the global `updated_at +
default_retention_days` check.
- # Populated via task_state_store.set(retention_days=N) for keys that
should expire differently
- # than the deployment wide default.
+ # Absolute UTC timestamp which denotes expiry of this row. CLI cleanup
will delete this row once
+ # (WHERE expires_at < now()). Computed at write time from the explicit
+ # ``retention`` argument or the global ``default_retention_days`` config.
+ # NULL means the row is never deleted by cleanup.
expires_at: Mapped[datetime | None] = mapped_column(UtcDateTime,
nullable=True)
__table_args__ = (