问题:
python错误提示:
UnicodeDecodeError: 'ascii' codec can't decode byte 0xb0 in position 1: ordinal not in range(128)
解决办法:
修改原函数为:
try: ctype = ctype.encode(default_encoding) # omit in 3.x! # except UnicodeEncodeError: except UnicodeError: pass
注释了原来的异常判断。