pankajkoti commented on code in PR #31595:
URL: https://github.com/apache/airflow/pull/31595#discussion_r1209283085
##########
airflow/providers/cncf/kubernetes/operators/pod.py:
##########
@@ -696,10 +698,11 @@ def cleanup(self, pod: k8s.V1Pod, remote_pod: k8s.V1Pod):
f"Pod {pod and pod.metadata.name} returned exit code "
f"{self.skip_on_exit_code}. Skipping."
)
- raise AirflowException(
- f"Pod {pod and pod.metadata.name} returned a
failure:\n{error_message}\n"
- f"remote_pod: {remote_pod}"
- )
+ raise AirflowException('\n'.join(filter(None, [
+ f"Pod {pod and pod.metadata.name} returned a failure.",
+ error_message,
Review Comment:
I think a new line to separate this would be nicer. Also, previously if the
value was not set, we were converting it to an empty string. Now, we're not
converting it to an empty string, would it have some impact?
--
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]