vincbeck commented on code in PR #48070:
URL: https://github.com/apache/airflow/pull/48070#discussion_r2012610357


##########
airflow-core/src/airflow/dag_processing/collection.py:
##########
@@ -197,6 +197,7 @@ def _serialize_dag_capturing_errors(
             session=session,
         )
         if dag_was_updated:
+            if "FabAuthManager" in conf.get("core", "auth_manager"):
             _sync_dag_perms(dag, session=session)

Review Comment:
   `_sync_dag_perms` only works if FAB auth manager is configured. I think we 
should move the check `if "FabAuthManager" in conf.get("core", 
"auth_manager"):` into `_sync_dag_perms`



##########
airflow-core/src/airflow/dag_processing/collection.py:
##########
@@ -197,6 +197,7 @@ def _serialize_dag_capturing_errors(
             session=session,
         )
         if dag_was_updated:
+            if "FabAuthManager" in conf.get("core", "auth_manager"):
             _sync_dag_perms(dag, session=session)

Review Comment:
   And one nit. I would actually use `if isinstance(get_auth_manager(), 
FabAuthManager)` but this is more a personal opinion



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to