i searched bit this. of people want convert original string(테스트) unicode(\ud14c\uc2a4\ud2b8).
but what want converting unicode string(such \ud14c\uc2a4\ud2b8) real string(테스트). have json file in korean strings in form of unicode(\uxxxx) , have parse original string. how can in python?
to sum up,
the way convert unicode string original string such in python \ud14c\uc2a4\ud2b8 -> 테스트
import codecs file_variable = 'path/to/file.json' codecs.open(file_variable, encoding='utf-8') file: json_object = json.load(file)
see if allows handle json in unicode. import codecs allows use .encode() , .decode() functions go , forth between unicode , unicode escaped:
string = ((some unicode text here)) string.decode('utf-8') string.encode('utf-8')