python 保存含有中文字符的序列乱码,
import sys
reload(sys)
sys.setdefaultencoding("utf-8")
import json
with open("xxx.json".decode("utf-8"),"w") as out: json.dump(res_list,out,ensure_ascii=False)
问题解决
python 保存含有中文字符的序列乱码,
import sys
reload(sys)
sys.setdefaultencoding("utf-8")
import json
with open("xxx.json".decode("utf-8"),"w") as out: json.dump(res_list,out,ensure_ascii=False)
问题解决