This is an automated email from the ASF dual-hosted git repository.
jscheffl 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 62d60e4af15 Fix Helm chart executor label to support executor aliases
(#67762)
62d60e4af15 is described below
commit 62d60e4af15eab925966bde19b4c8e7a05b91b1c
Author: Anurag Pappula <[email protected]>
AuthorDate: Sat May 30 14:26:43 2026 +0530
Fix Helm chart executor label to support executor aliases (#67762)
* Fix Helm chart executor label to support executor aliases
The scheduler Deployment/StatefulSet renders the executor option into a
Kubernetes label and only sanitized the comma separator used between
multiple executors. Executor aliases (name:ExecutorClass) contain a
colon, which is not a valid label character, so a value such as
CeleryExecutor,harvest_exec:KubernetesExecutor produced an invalid label
and the scheduler failed to deploy.
Replace the colon with a hyphen alongside the existing comma handling so
aliased and multi-executor configurations render a valid label.
* Add newsfragment for executor alias label fix
* Remove newsfragment; not needed for a bugfix per AGENTS.md
---
chart/templates/scheduler/scheduler-deployment.yaml | 2 +-
chart/tests/helm_tests/airflow_aux/test_basic_helm_chart.py | 3 +++
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/chart/templates/scheduler/scheduler-deployment.yaml
b/chart/templates/scheduler/scheduler-deployment.yaml
index 294975fab0a..5f2846c3c7e 100644
--- a/chart/templates/scheduler/scheduler-deployment.yaml
+++ b/chart/templates/scheduler/scheduler-deployment.yaml
@@ -50,7 +50,7 @@ metadata:
release: {{ .Release.Name }}
chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
heritage: {{ .Release.Service }}
- executor: {{ .Values.executor | replace "," "-" | trunc 63 | trimSuffix
"-" | trimSuffix ":" | trimSuffix "_" | trimSuffix "." | quote }}
+ executor: {{ .Values.executor | replace "," "-" | replace ":" "-" | trunc
63 | trimSuffix "-" | trimSuffix ":" | trimSuffix "_" | trimSuffix "." | quote
}}
{{- with .Values.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
diff --git a/chart/tests/helm_tests/airflow_aux/test_basic_helm_chart.py
b/chart/tests/helm_tests/airflow_aux/test_basic_helm_chart.py
index 4bdd23fdb77..3d1dbfe38b0 100644
--- a/chart/tests/helm_tests/airflow_aux/test_basic_helm_chart.py
+++ b/chart/tests/helm_tests/airflow_aux/test_basic_helm_chart.py
@@ -204,6 +204,7 @@ class TestBaseChartTest:
[
"CeleryExecutor",
"CeleryExecutor,KubernetesExecutor",
+ "CeleryExecutor,harvest_exec:KubernetesExecutor",
],
)
def test_labels_are_valid(self, executor):
@@ -326,6 +327,8 @@ class TestBaseChartTest:
expected_labels["executor"] = "CeleryExecutor"
if executor == "CeleryExecutor,KubernetesExecutor":
expected_labels["executor"] =
"CeleryExecutor-KubernetesExecutor"
+ elif executor ==
"CeleryExecutor,harvest_exec:KubernetesExecutor":
+ expected_labels["executor"] =
"CeleryExecutor-harvest_exec-KubernetesExecutor"
if (
executor == "CeleryExecutor"