You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "1fanwang (via GitHub)" <gi...@apache.org> on 2026/07/29 23:53:17 UTC

Re: [PR] AIP-97: Disruption Readiness (Transparent Infra Failure Retries through Context Capture and Propagation) [airflow]

1fanwang commented on code in PR #66405:
URL: https://github.com/apache/airflow/pull/66405#discussion_r3678834923


##########
providers/cncf/kubernetes/src/airflow/providers/cncf/kubernetes/executors/kubernetes_executor_utils.py:
##########
@@ -329,18 +330,20 @@ def process_status(
             # since kube server have received request to delete pod set TI state failed
             if event["type"] == "DELETED" and pod.metadata.deletion_timestamp:
                 self.log.info(
-                    "Event: Pod %s deleted before it could complete, annotations: %s",
+                    "Event: Pod %s deleted while running, annotations: %s",
                     pod_name,
                     annotations_string,
                 )
+                # An Airflow-initiated stop sets the TI terminal first, so the scheduler
+                # excludes that case by state and only a real disruption reaches here.
                 self.watcher_queue.put(
                     KubernetesWatch(
                         pod_name,
                         namespace,
                         TaskInstanceState.FAILED,
                         annotations,
                         resource_version,
-                        None,
+                        {"pod_status": "Running", "pod_reason": POD_DELETED_REASON},

Review Comment:
   can we use kwargs, same everywhere



-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org