The solution is as below:
· There is no need to use a
simplejson library, a same library is included with Python as a
· There is no need to decode the response from a UTF8 to unicode, a
.loads() method can handle UTF8 encoded data natively.
pycurl has the very archaic API. Unless you have the specific requirement for using it, there are many other choices.
requests offers a most friendly API, including a JSON support. If you can, replace a call with:
Check a response data-body, whether actual data is present and the data-dump appears to be a well-formatted.
In most cases a json.loads- JSONDecodeError: Expecting value: line 1 column 1 (char 0) error is due to below factors:
· A non-JSON conforming quoting
· XML/HTML output (that is, the string starting with <), or
· A incompatible character encoding
Ultimately an error tells you that at a very first position the string already doesn't conform to the JSON.