Skip to content

[release-0.6] Do not decode response data in Python2#329

Merged
fabianvf merged 1 commit intoopenshift:release-0.6from
openshift-cherrypick-robot:cherry-pick-225-to-release-0.6
Oct 22, 2019
Merged

[release-0.6] Do not decode response data in Python2#329
fabianvf merged 1 commit intoopenshift:release-0.6from
openshift-cherrypick-robot:cherry-pick-225-to-release-0.6

Conversation

@openshift-cherrypick-robot

This is an automated cherry-pick of #225

/assign fabianvf

response data is already str in Python2 so it doesn't need to be decoded.
Furthermore, as decode() uses ascii by default in PY2, it breaks in case of a non-ascii character the response.
Just mimic what kubernetes do in https://github.com/kubernetes-client/python/blob/master/kubernetes/client/rest.py#L216
Fix openshift#224
@openshift-ci-robot openshift-ci-robot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Oct 22, 2019
@fabianvf fabianvf merged commit bf4dc71 into openshift:release-0.6 Oct 22, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants