天天看点

成功解决File "f:\program files\python\python36\lib\re.py", line 142, in <modul

解决问题

 File "f:\program files\python\python36\lib\re.py", line 142, in

   class RegexFlag(enum.IntFlag):

AttributeError: module 'enum' has no attribute 'IntFlag'

解决思路

属性错误:模块“enum”没有属性“intflag”

解决方法

很可能是因为设置了PYTHONPATH环境变量。这将导致无法调用正常的自己的库,因此建议在打开python前执行 unset PYTHONPATH