Closed qaqFei closed 4 months ago
添加,encoding='utf-8'即可
with open('tips.json','w',encoding='utf-8') as f: f.write(json.dumps(tip_info,indent=4,ensure_ascii=False))
感谢Issue!
我主要是用 Termux 测试的,没在 Windows 上跑过,可能会有大大小小的编码问题。
顺便提一句 Windows 的编码就是史
已修改,再次感谢提醒! 手上暂时没有 Windows 设备,issue先关了,有bug的话可以再开
添加,encoding='utf-8'即可
with open('tips.json','w',encoding='utf-8') as f: f.write(json.dumps(tip_info,indent=4,ensure_ascii=False))