bdsoha commented on code in PR #26766:
URL: https://github.com/apache/airflow/pull/26766#discussion_r985281903


##########
airflow/providers/cncf/kubernetes/utils/xcom_sidecar.py:
##########
@@ -47,13 +47,15 @@ class PodDefaults:
     )
 
 
-def add_xcom_sidecar(pod: k8s.V1Pod) -> k8s.V1Pod:
+def add_xcom_sidecar(pod: k8s.V1Pod, image: str) -> k8s.V1Pod:

Review Comment:
   Moved to `kwargs`



##########
airflow/providers/cncf/kubernetes/hooks/kubernetes.py:
##########
@@ -368,6 +371,11 @@ def get_namespace(self) -> str | None:
             return namespace
         return None
 
+    def get_xcom_sidecar_container_image(self):
+        """Returns the xcom sidecar image that defined in the connection"""
+        image = self._get_field("xcom_sidecar_container_image")
+        return image if image else "alpine"

Review Comment:
   No need to append `or None`, as the `_get_field` already returns `None` for 
missing values.



-- 
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]

Reply via email to