You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Webserver cannot read logs of pods launched by a scheduler of mismatching Airflow version #42753
The webserver was unable to fetch the logs of task instance.
*** No logs found in GCS; ti=%s <TaskInstance: long_running_tasks_poc_copy.simple_kpo scheduled__2024-10-03T00:00:00+00:00 [running]>
*** Attempting to fetch logs from pod long-running-tasks-poc-copy-simple-kpo-k5v9qx6i through kube API
*** Reading from k8s pod logs failed: ('Cannot find pod for ti %s', <TaskInstance: long_running_tasks_poc_copy.simple_kpo scheduled__2024-10-03T00:00:00+00:00 [running]>)
The corresponding Kubernetes worker pod was in the running phase but the weberver could not find the pod in the namespace. It turns out it was because the label selector was not matching for the label airflow-version. The pod had the label airflow-version=2.9.3+astro.4 and the webserver was using the Airflow version 2.9.3+astro.5 which created the label selector airflow-version=2.9.3+astro.5.
The reason why the version were different is because the deployment's Airflow version was upgraded from 2.9.3+astro.4 to 2.9.3+astro.5 after the task instance was launched.
Activity