Skip to content

Commit

Permalink
Remove internal api call decorator from trigger_dag.py (apache#44490)
Browse files Browse the repository at this point in the history
  • Loading branch information
shahar1 authored Nov 29, 2024
1 parent 13e5464 commit 2bc8617
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions airflow/api/common/trigger_dag.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
import json
from typing import TYPE_CHECKING

from airflow.api_internal.internal_api_call import internal_api_call
from airflow.exceptions import DagNotFound, DagRunAlreadyExists
from airflow.models import DagBag, DagModel, DagRun
from airflow.models.dag_version import DagVersion
Expand Down Expand Up @@ -108,7 +107,6 @@ def _trigger_dag(
return dag_run


@internal_api_call
@provide_session
def trigger_dag(
dag_id: str,
Expand All @@ -124,12 +122,12 @@ def trigger_dag(
Triggers execution of DAG specified by dag_id.
:param dag_id: DAG ID
:param triggered_by: the entity which triggers the dag_run
:param run_id: ID of the dag_run
:param conf: configuration
:param logical_date: date of execution
:param replace_microseconds: whether microseconds should be zeroed
:param session: Unused. Only added in compatibility with database isolation mode
:param triggered_by: the entity which triggers the dag_run
:return: first dag run triggered - even if more than one Dag Runs were triggered or None
"""
dag_model = DagModel.get_current(dag_id)
Expand Down

0 comments on commit 2bc8617

Please sign in to comment.