This is an automated email from the ASF dual-hosted git repository.

Lee-W pushed a commit to branch v3-3-test
in repository https://gitbox.apache.org/repos/asf/airflow.git


The following commit(s) were added to refs/heads/v3-3-test by this push:
     new 13d079f1fe0 [v3-3-test] Fix runtime-partition example Dags using 
unreachable schedules (#68719) (#68803)
13d079f1fe0 is described below

commit 13d079f1fe07d774993b4904b6c7134cd2857f8e
Author: github-actions[bot] 
<41898282+github-actions[bot]@users.noreply.github.com>
AuthorDate: Mon Jun 22 14:53:37 2026 +0800

    [v3-3-test] Fix runtime-partition example Dags using unreachable schedules 
(#68719) (#68803)
    
    Co-authored-by: Wei Lee <[email protected]>
---
 .../src/airflow/example_dags/example_asset_partition.py    | 14 ++++++++------
 1 file changed, 8 insertions(+), 6 deletions(-)

diff --git a/airflow-core/src/airflow/example_dags/example_asset_partition.py 
b/airflow-core/src/airflow/example_dags/example_asset_partition.py
index baba6ced1fc..549db8cef96 100644
--- a/airflow-core/src/airflow/example_dags/example_asset_partition.py
+++ b/airflow-core/src/airflow/example_dags/example_asset_partition.py
@@ -160,15 +160,17 @@ regional_sales = 
Asset(uri="file://incoming/sales/regional.csv", name="regional_
 
 with DAG(
     dag_id="ingest_regional_sales",
-    schedule=CronPartitionTimetable("0 * * * *", timezone="UTC"),
+    schedule=PartitionAtRuntime(),
     tags=["example", "sales", "ingestion"],
 ):
-    """Produce hourly regional sales data with composite partition keys."""
+    """Produce regional sales data with composite ``region|timestamp`` 
partition keys at runtime."""
 
     @task(outlets=[regional_sales])
-    def ingest_sales():
-        """Ingest regional sales data partitioned by region and time."""
-        pass
+    def ingest_sales(*, outlet_events=None):
+        """Emit one composite ``region|timestamp`` partition per region."""
+        timestamp = "2026-06-14T03:00:00"
+        for region in ("us", "eu", "apac"):
+            
outlet_events[regional_sales].add_partitions(f"{region}|{timestamp}")
 
     ingest_sales()
 
@@ -205,7 +207,7 @@ region_raw_stats = 
Asset(uri="file://incoming/player-stats/by-region.csv", name=
 
 with DAG(
     dag_id="ingest_region_stats",
-    schedule=None,
+    schedule=PartitionAtRuntime(),
     tags=["example", "player-stats", "regional"],
 ):
     """

Reply via email to