Home > Q&A > body text
1处打印出来的在3处翻译过来大概是下图
2出报错在4处,求解Python编码问题
加了encode('utf-8')之后上面的好了,但在以path为文件名创建文件夹时报WindowsError(123)错误
ringa_lee2017-04-18 10:29:02
You can try title.encode(utf8) in the printing place
巴扎黑2017-04-18 10:29:02
str() cannot convert Unicode strings. To convert unicode to str, use encode(). Change the file name.