Skip to content

Fix improper json response handling of read_namespaced_pod_log

DCausse requested to merge fix-json-log-output into main

The k8s client is making a bold assumption that any response that can be parsed as json should be parsed, unfortunately the read_namespaced_pod_log is explicitely asking for a string response but in this case the dictionnary obtained after parsing the json response is naively serialized using python string representation which is no longer the orignal json output we obtained from the container. Disable the k8s client response handling by passing _preload_content=False so that the response data can be inspected by the caller letting it do what it wants with the raw log output.

Bug: T378382

Merge request reports

Loading