uranusjr commented on code in PR #67537:
URL: https://github.com/apache/airflow/pull/67537#discussion_r3401542608
##########
airflow-core/src/airflow/timetables/base.py:
##########
@@ -258,6 +258,22 @@ def get_partition_mapper(self, *, name: str = "", uri: str
= "") -> PartitionMap
)
raise NotImplementedError(msg)
+ def iter_partition_dagrun_infos(
+ self,
+ *,
+ earliest_date: datetime.date,
+ latest_date: datetime.date,
+ ) -> Iterable[DagRunInfo]:
+ """
+ Yield one DagRunInfo per partition for calendar days in
``[earliest_date, latest_date]`` (both inclusive).
+
+ Only called for partitioned timetables (``partitioned is True``). The
default
+ implementation raises :exc:`NotImplementedError`; timetables that set
+ ``partitioned = True`` must override this.
+ """
+ msg = f"{type(self).__name__} is partitioned but does not implement
iter_partition_dagrun_infos."
+ raise NotImplementedError(msg)
Review Comment:
Not critical, but maybe we should have a `PartitionedTimetable` intermediate
class to host this, instead of putting this empty function on every timetable
type.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]