Python的json模块解析单引号数据会报错,示例如下
>>> import json
>>> data = "{'field1': 0, 'field2': 'hehehehe', 'field3': 'hahaha'}"
>>> json.loads(data)
Traceback (most recent call last):
File “”, line 1, in
File “/usr/lib/python3.5/json/init.py”, line 319, in loads
return _default_decoder.decode(s)
File “/usr/lib/python3.5/json/decoder.py”, line 339, in decode
obj, end = self.raw_