raphaelauv commented on code in PR #76497:
URL: https://github.com/apache/airflow/pull/76497#discussion_r4618858564


##########
providers/cncf/kubernetes/tests/unit/cncf/kubernetes/utils/test_pod_manager.py:
##########
@@ -1346,12 +1352,38 @@ def test_extract_xcom_success(
         mock_pod = MagicMock()
         mock_client = MagicMock()
         mock_client.peek_stderr.return_value = ""
-        mock_client.read_all.return_value = xcom_json
+        mock_client.read_all.return_value = xcom_json.encode()
         mock_kubernetes_stream.return_value = mock_client
         ret = self.pod_manager.extract_xcom(pod=mock_pod)
         assert ret == xcom_json
         assert mock_exec_xcom_kill.call_count == 1
 
+    @mock.patch("kubernetes.stream.ws_client.create_websocket")

Review Comment:
   I do not see another way to splits an "é" across two frames, which is the 
bug. A mock of `kubernetes_stream` can't reproduce that.
   
   I'm going to add a an explicit pytest.mark.execution_timeout on this test



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