You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using ResourceManager.cluster_submit_application() to submit a YARN application, the response is not properly handled and results in the following traceback...
File "/opt/anaconda2/envs/py3/lib/python3.6/site-packages/yarn_api_client/resource_manager.py", line 397, in cluster_submit_application
return self.request(path, 'POST', data=data)
File "/opt/anaconda2/envs/py3/lib/python3.6/site-packages/yarn_api_client/base.py", line 84, in request
return self.response_class(response)
File "/opt/anaconda2/envs/py3/lib/python3.6/site-packages/yarn_api_client/base.py", line 23, in __init__
self.data = response.json()
File "/opt/anaconda2/envs/py3/lib/python3.6/site-packages/requests/models.py", line 897, in json
return complexjson.loads(self.text, **kwargs)
File "/opt/anaconda2/envs/py3/lib/python3.6/json/__init__.py", line 354, in loads
return _default_decoder.decode(s)
File "/opt/anaconda2/envs/py3/lib/python3.6/json/decoder.py", line 339, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/opt/anaconda2/envs/py3/lib/python3.6/json/decoder.py", line 357, in raw_decode
raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
The issue appears to be related to responses that contain no content. In my opinion, this is a bug with response.json(), but we should probably handle this.
The request status code is the expected 202, but there is no "location" entry as described in the REST API. I see an empty response using other REST clients as well.
This was discovered while troubleshooting #75 and the python file included in that issue can be used to reproduce this.
This could very well be an issue with the Hadoop cluster I'm running against also. (HDP 2.7.3.2.6.5.0-292)
The text was updated successfully, but these errors were encountered:
kevin-bates
added a commit
to kevin-bates/hadoop-yarn-api-python-client
that referenced
this issue
Jan 11, 2020
Application submission via the REST API does not return a response
body. This updates ensures that an empty dictionary is returned
in such cases.
Fixes: gateway-experiments#76
Application submission via the REST API does not return a response
body. This updates ensures that an empty dictionary is returned
in such cases.
Fixes: #76
When using
ResourceManager.cluster_submit_application()
to submit a YARN application, the response is not properly handled and results in the following traceback...The issue appears to be related to responses that contain no content. In my opinion, this is a bug with response.json(), but we should probably handle this.
The request status code is the expected
202
, but there is no "location" entry as described in the REST API. I see an empty response using other REST clients as well.This was discovered while troubleshooting #75 and the python file included in that issue can be used to reproduce this.
This could very well be an issue with the Hadoop cluster I'm running against also. (HDP 2.7.3.2.6.5.0-292)
The text was updated successfully, but these errors were encountered: