Overview
Airflow 3.1, released on September 25, 2025, adds OpenTelemetry support and @skip_if / @run_if decorators for conditional task control.
Main Features
OpenTelemetry and conditional decorators
OpenTelemetry enables exporting traces and metrics to backends like Jaeger or Prometheus. The @skip_if and @run_if decorators simplify conditional DAG logic.
python
from airflow.decorators import task, dag
from airflow.decorators import skip_if, run_if
from datetime import datetime
@dag(schedule='@daily', start_date=datetime(2025, 1, 1))
def my_dag():
@task
@skip_if(lambda ctx: ctx['ds_nodash'] == '20250101')
def process_data():
return 'processed'
@task
@run_if(lambda ctx: ctx['dag_run'].conf.get('full'))
def full_refresh():
return 'refreshed'
process_data() >> full_refresh()
my_dag()
