Skip to content

TriggerDagRunOperator DAG task log showing Warning: Unable to redact <DagRunState.SUCCESS: 'success'> #33061

Description

@vatsrahul1001

Apache Airflow version

main (development)

What happened

When TriggerDagRunOperator task log showing below warning
WARNING - Unable to redact <DagRunState.SUCCESS: 'success'>, please report this via <https://github.com/apache/airflow/issues>. Error was: TypeError: EnumMeta.__call__() missing 1 required positional argument: 'value'

image

What you think should happen instead

There should not be any warning in logs

How to reproduce

Steps to Repo:

  1. Launch airflow using Breeze with main
  2. Trigger any TriggerDagRunOperator
  3. Check logs

DAG :

from airflow import DAG
from airflow.operators.trigger_dagrun import TriggerDagRunOperator
from airflow.operators.dummy import DummyOperator
from airflow.utils.dates import days_ago

"""This example illustrates the use of the TriggerDagRunOperator. There are 2
entities at work in this scenario:
1. The Controller DAG - the DAG that conditionally executes the trigger
2. The Target DAG - DAG being triggered (in trigger_dagrun_target.py)

"""

dag = DAG(
    dag_id="trigger_controller_dag",
    default_args={"owner": "airflow", "start_date": days_ago(2)},
    schedule_interval=None,
    tags=["core"],
)


trigger = TriggerDagRunOperator(
    task_id="test_trigger_dagrun",
    trigger_dag_id="trigger_target_dag",
    reset_dag_run=True,
    wait_for_completion=True,
    conf={"message": "Hello World"},
    dag=dag,
)

Note: create a DAG trigger_target_dag which maybe sleeps for sometime

Operating System

OS x

Versions of Apache Airflow Providers

No response

Deployment

Docker-Compose

Deployment details

No response

Anything else

No response

Are you willing to submit PR?

  • Yes I am willing to submit a PR!

Code of Conduct

Metadata

Metadata

Labels

affected_version:main_branchIssues Reported for main branchkind:bugThis is a clearly a bugpriority:highHigh priority bug that should be patched quickly but does not require immediate new release

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions