ramziash commented on code in PR #74583:
URL: https://github.com/apache/airflow/pull/74583#discussion_r4334583557
##########
task-sdk/src/airflow/sdk/definitions/timetables/assets.py:
##########
@@ -77,6 +77,10 @@ class PartitionedAssetTimetable(AssetTriggeredTimetable):
partition_mapper_config: dict[BaseAsset, PartitionMapper] =
attrs.field(factory=dict)
default_partition_mapper: PartitionMapper = IdentityMapper()
+ # Opt-in refire on late/corrected partition events: "rerun" (clear +
re-run the
+ # existing DagRun, attempts increment) or "newrun" (a new DagRun per
refire).
+ # None = fire once (default, no behavior change).
+ refire_policy: str | None = None
Review Comment:
Good catch . refire_policy is just checked with == "rerun" in the scheduler,
so any unrecognized value (typo, wrong case, trailing whitespace) silently
falls through to the new-run path instead of erroring.
Pushed a fix: PartitionedAssetTimetable.validate() now rejects anything
other than None, "rerun", "newrun" with AirflowTimetableInvalid, consistent
with how batch_asset_events/rollup requirements are already validated there.
--
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]