henry3260 commented on code in PR #76351:
URL: https://github.com/apache/airflow/pull/76351#discussion_r4497387555
##########
providers/cncf/kubernetes/src/airflow/providers/cncf/kubernetes/triggers/pod.py:
##########
@@ -392,6 +393,25 @@ async def _wait_for_container_completion(self) ->
TriggerEvent:
)
pod = await self._get_pod()
pod_container_state = self.define_pod_container_state(pod)
+ if pod_container_state == ContainerState.UNDEFINED and not
self.has_base_container_in_spec(pod):
+ # Polling cannot make a container the pod never declares
appear, and
+ # ``_execution_deadline`` is only set when the task sets
``execution_timeout``,
+ # so without this the loop would keep polling until the pod
reaches a
+ # terminal phase.
+ return TriggerEvent(
Review Comment:
Thanks for catching that, really goooood call :)
--
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]