文章目录
- 一、运行后报错如AttributeError: module 'OpenSSL.SSL' has no attribute 'SSLv3_METHOD'
- 二、再运行又报错如AttributeError: module ‘lib‘ has no attribute
一、运行后报错如AttributeError: module ‘OpenSSL.SSL’ has no attribute ‘SSLv3_METHOD’
原因:因为pyopenssl的版本过高,卸载后,下pyopenssl-22.0.0版本
解决方案如下:
pip uninstall pyopenssl
pip install pyopenssl==22.0.0 -i https://mirrors.aliyun.com/pypi/simple/
二、再运行又报错如AttributeError: module ‘lib‘ has no attribute
原因:因为cryptography版本过高,卸载后,下载cryptography-36.0.2版本
解决方案如下:
pip uninstall cryptography
pip install cryptography==36.0.2 -i https://mirrors.aliyun.com/pypi/simple/