[python] json dump 한글 깨짐


[python] json dump 한글 깨짐

#python #json #dump json file을 읽어들어오는데는 문제가 없었지만, dump하는 과정에서 한글이 유니코드로 보이는 문제가 있었다. import json data = json.load(file) print(json.dumps(data)) #{word:'w\u3141'} 이를 해결하기 위해 ensure_ascii=False 을 집어넣으니 한글이 제대로 보였다. import json data = json.load(file) print(json.dumps(data, ensure_ascii=False)) #{word:'한글'}...

[python] json dump 한글 깨짐에 대한 요약내용입니다.

자세한 내용은 아래에 원문링크를 확인해주시기 바랍니다.


#dump #json #python

원문링크 : [python] json dump 한글 깨짐