Skip to content

airflow sync-perm --include-dags can fail due to a single misconfigured DAG #71795

Closed

Description

@zhaorui2022

Under which category would you file this issue?

Providers

Apache Airflow version

3.2.2

What happened and how to reproduce it?

To reproduce the issue:

  1. Create a dummy dag, and in access control block of the DAG, set a role that doesn't exist in the Airflow
  2. This DAG shows up with import errors on Airflow UI, but still in serialized dags table
  3. In the same container, or another container connecting to the same Airflow metadata DB, run airflow sync-perm --include-dags. It will fail with a FABException saying the role for that bad DAG doesn't exist, and it blocks permission sync for all other good DAGs.

What you think should happen instead?

Bad/Misconfigured DAGs or non-existing roles should be ignored when running airflow sync-perm --include-dags, or at least, it should continue syncing permissions for other DAGs, instead of stopping at the misconfigured DAG.

Operating System

No response

Deployment

None

Apache Airflow Provider(s)

fab

Versions of Apache Airflow Providers

3.6.4

Official Helm Chart version

Not Applicable

Kubernetes Version

No response

Helm Chart configuration

No response

Docker Image customizations

Official 3.2.2 docker image

Anything else?

No response

Are you willing to submit PR?

  • Yes I am willing to submit a PR!

Code of Conduct

Activity

  1. added
    kind:bug
    needs-triage
    on Aug 18, 2026
  2. zhaorui2022 commented on Aug 19, 2026

    @zhaorui2022
    Author

    Another thought, would it make sense to skip the serialized dags with import errors? These misconfigured dags end up in the serialized dag tables but they have has_import_errors=1 in dag table.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:authkind:bugneeds-triage

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions