UnicodeDecodeError ascii codec can't decode byte 0xe5 in position 0 ordinal not in range(128)
运行python程序时出现以下错误:
UnicodeDecodeError: ‘ascii’ codec can’t decode byte 0xe5 in position 0: ordinal not in range(128)
Figured it out.
I put the following at the start of my python file
import sys
reload(sys)
sys.setdefaultencoding("utf-8")
浙公网安备 33010602011771号