This is an automated email from the ASF dual-hosted git repository.

potiuk pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git


The following commit(s) were added to refs/heads/main by this push:
     new 3d89e75eb9 Fix failing Celery Executor tests after config migration 
(#32763)
3d89e75eb9 is described below

commit 3d89e75eb98d16989d91f5c22dd153b6e51cb42e
Author: Jarek Potiuk <[email protected]>
AuthorDate: Sat Jul 22 09:55:16 2023 +0200

    Fix failing Celery Executor tests after config migration (#32763)
    
    The Celery Executor tests in Helm started to fail after the
    configuration migration has been merged (#32604). The PR did not
    have "full tests needed" label and it skipped K8S tests because
    there was no change related to kubernetes (but some fundamental
    changes in how configuration were retrieved caused the Celery
    Executor failed on missing default configuration value.
    
    The change adds ProvidersManager configuration initialization when
    executors are started in order to fix the problem temporarily,
    however there is an ongoing effort to optimise the path of
    retrieving provider configuration without having to initialize
    all provider's configuration and those lines will be removed
    when it happens.
---
 airflow/executors/executor_loader.py | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/airflow/executors/executor_loader.py 
b/airflow/executors/executor_loader.py
index 58cd9ae916..816e172140 100644
--- a/airflow/executors/executor_loader.py
+++ b/airflow/executors/executor_loader.py
@@ -98,6 +98,9 @@ class ExecutorLoader:
 
         :return: an instance of executor class via executor_name
         """
+        from airflow.providers_manager import ProvidersManager
+
+        ProvidersManager().initialize_providers_configuration()
         if executor_name == CELERY_KUBERNETES_EXECUTOR:
             return cls.__load_celery_kubernetes_executor()
         elif executor_name == LOCAL_KUBERNETES_EXECUTOR:

Reply via email to