When using "faulty" credentials we get a JSONDecodeError.
Closed this issue · 1 comments
falkowich commented
Seems like a regression.
(ise) falk@broekn-home:~/dev/ise$ /home/falk/.local/share/virtualenvs/ise-B3LG4bZL/bin/python /home/falk/dev/ise/test/test_ers.py
{'success': False, 'response': '', 'error': ''} <Response [401]>
<Response [401]>
Traceback (most recent call last):
File "/home/falk/dev/ise/test/test_ers.py", line 187, in <module>
add_endpoint(endpoint)
File "/home/falk/dev/ise/test/test_ers.py", line 24, in add_endpoint
test = ise.add_endpoint(endpoint['name'], endpoint['mac'], endpoint['group-id']) # noqa: E501
File "./ise.py", line 353, in add_endpoint
return ERS._pass_ersresponse(result, resp)
File "./ise.py", line 77, in _pass_ersresponse
print(resp.json())
File "/home/falk/.local/share/virtualenvs/ise-B3LG4bZL/lib/python3.7/site-packages/requests/models.py", line 898, in json
return complexjson.loads(self.text, **kwargs)
File "/usr/lib/python3.7/json/__init__.py", line 348, in loads
return _default_decoder.decode(s)
File "/usr/lib/python3.7/json/decoder.py", line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/usr/lib/python3.7/json/decoder.py", line 355, in raw_decode
raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
falkowich commented
Any moar ideas on this?