Skip to content

Commit

Permalink
refactor(utils/context): remove the dataset_alias_events deduplicatio…
Browse files Browse the repository at this point in the history
…n in OutletEventAccessor

handle the deduplication in taskinstance all at once
  • Loading branch information
Lee-W committed Sep 12, 2024
1 parent e8176b7 commit 35c5651
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions airflow/utils/context.py
Original file line number Diff line number Diff line change
Expand Up @@ -193,8 +193,7 @@ def add(self, dataset: Dataset | str, extra: dict[str, Any] | None = None) -> No
event = DatasetAliasEvent(
source_alias_name=dataset_alias_name, dest_dataset_uri=dataset_uri, extra=extra or {}
)
if event not in self.dataset_alias_events:
self.dataset_alias_events.append(event)
self.dataset_alias_events.append(event)


class OutletEventAccessors(Mapping[str, OutletEventAccessor]):
Expand Down

0 comments on commit 35c5651

Please sign in to comment.