use the json.dumps
method to convert the dictionary to json string, which is not displayed in Chinese. ensure_ascii
is set to False
the converted string is:
{"first": {"value": "\xe8\xae\xa2\xe5\x8d\x95\xe9\x80\x9a\xe7\x9f\xa5", "color": "-sharp173177"}, "keyword1": {"value": "201804271644432959", "color": "-sharp173177"}, "keyword2": {"value": "\xe8\xae\xa2\xe5\x8d\x95\xe9\xa2\x84\xe5\xae\x9a\xe6\x88\x90\xe5\x8a\x9f", "color": "-sharp173177"}, "keyword3": {"value": "2018-04-27 16:44:43", "color": "-sharp173177"}, "remark": {"value": "\xe6\x81\xad\xe5\x96\x9c\xe6\x82\xa8\xef\xbc\x8c\xe8\xae\xa2\xe5\x8d\x95\xe9\xa2\x84\xe5\xae\x9a\xe6\x88\x90\xe5\x8a\x9f\xef\xbc\x8c\xe6\x82\xa8\xe5\x8f\xaf\xe4\xbb\xa5\xe7\x82\xb9\xe5\x87\xbb\xe6\x9f\xa5\xe7\x9c\x8b\xe6\xad\xa4\xe8\xae\xa2\xe5\x8d\x95\xe8\xaf\xa6\xe6\x83\x85", "color": "-sharp000000"}}
Python version 3. 6
look it up on the Internet, but there is no answer
ask the bosses to tell you the reasons and solutions