成功解决AttributeError: module ‘enum‘ has no attribute ‘IntFlag‘?
成功解決AttributeError: module 'enum' has no attribute 'IntFlag'?
目錄
解決問(wèn)題
解決思路
解決方法
解決問(wèn)題
AttributeError: module 'enum' has no attribute 'IntFlag'?
解決思路
This is likely caused by the package enum34. Since python 3.4 there's a standard library enum module, so you should uninstall enum34, which is no longer compatible with the enum in the standard library since enum.IntFlag was added in python 3.6.
這可能是由包Enum34引起的。因?yàn)镻ython3.4有一個(gè)標(biāo)準(zhǔn)庫(kù)枚舉模塊,所以您應(yīng)該卸載Enum34,因?yàn)樵赑ython3.6中添加了Enum.Intflag,所以它不再與標(biāo)準(zhǔn)庫(kù)中的枚舉兼容。
解決方法
pip uninstall enum34 ? #卸載enum34
大功告成!!哈哈!!
網(wǎng)友推薦解決方法:歡迎各路網(wǎng)友,前來(lái)共同探討出錯(cuò)問(wèn)題,解決bug,共享快樂(lè)!
用不了pip的網(wǎng)友,可直接刪掉\Lib\site-packages\enum打頭的兩個(gè)文件夾即可!
總結(jié)
以上是生活随笔為你收集整理的成功解决AttributeError: module ‘enum‘ has no attribute ‘IntFlag‘?的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問(wèn)題。
- 上一篇: Py之itchat:python库之it
- 下一篇: 成功解决UnicodeDecodeErr