会员
周边
新闻
博问
闪存
众包
赞助商
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
番茄土豆西红柿
新随笔
管理
2018年5月10日
python2.7运行出现的Warning: UnicodeWarning: Unicode equal comparison failed to convert both arguments to Unicode - interpreting them as being unequal
摘要: 运行出现如下错误 uncode编码警告:在unicode等价比较中,把两个参数同时转换为unicode编码失败。中断并认为他们不相等。 windows下的字符串str默认编码是ascii,而python编码是utf8 解决方法:添加如下几行代码 import sys reload(sys) sys.
阅读全文
posted @ 2018-05-10 15:24 番茄土豆西红柿
阅读(2233)
评论(0)
推荐(0)
TOP