Fix data decode for watch/watch.py:49 - #138
Conversation
…sition 2047: unexpected end of data``` on kubernetes/watch/watch.py:49
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: dbazhal The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
/assign roycaihw |
|
Issues go stale after 90d of inactivity. If this issue is safe to close now please do so with Send feedback to sig-testing, kubernetes/test-infra and/or fejta. |
| b'tus": {}}}\n' | ||
| b'{"type": "ADDED", "object": {"metadata": {"name": "test3",' | ||
| b'"resourceVersion": "3"}, "spec": {}, "status": {}}}\n', | ||
| b'should_not_happened\n']) |
There was a problem hiding this comment.
I'm confused. Does the Python 3 client always get byte formatted data in a watch response? If so, does that mean the Python 3 client never supported watch?
I'm not sure if I understand what triggers a byte formatted response from the apiserver. Could you add an e2e test in https://github.com/kubernetes-client/python/blob/master/kubernetes/e2e_test/test_client.py for watch, so that we can see watch works for both Python 2 and 3?
There was a problem hiding this comment.
I'm not sure, but it seems to me that yes, p3 always gets bytes. I'm not sure about 'never supported watch', I may guess that it's not working only if data contains non-ascii symbols.
Writing e2e test is a great idea, but I'm not quiet sure I understand how watch test should look like. If you could help me out with describing test case, I'd do it faster :)
In testcase test_watch I'm creating, let's say, configmap, remember it's revision, make changes to this configmap, and start watching it from saved revision, sounds legit?
|
/remove-lifecycle stale |
|
Issues go stale after 90d of inactivity. If this issue is safe to close now please do so with Send feedback to sig-testing, kubernetes/test-infra and/or fejta. |
|
Stale issues rot after 30d of inactivity. If this issue is safe to close now please do so with Send feedback to sig-testing, kubernetes/test-infra and/or fejta. |
|
Rotten issues close after 30d of inactivity. Send feedback to sig-testing, kubernetes/test-infra and/or fejta. |
|
@fejta-bot: Closed this PR. DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
There is error like
So this PR fixes that. Related somehow to #104