pycharm install third-party libraries error: AttributeError: 'module' object has no attribute 'main' pycharm install third-party libraries error: AttributeError: 'module' object has no attribute 'main'

pycharm install third-party libraries error: AttributeError: 'module' object has no attribute 'main'

 
After upgrading to 10.0.1 pip old version of pycharm use pip to install third-party libraries when it will error, error as shown above:

 

The main reason is the new pip changed some of the api which pip.main () instead pip_main (),

Legacy of pycharm referenced in packaging_tool.py in that pip.main () method, it will be an error.
The simplest, most perfect solution for:
\ Helper \ packaging_tool.py 1. Locate the file directory under pycharm
2. Replace the old version of the same name file packaging_tool.py new version of pycharm
ps: blogger pycharm is older version 2017.2.4 of the trial whether to try this method yet to be
 
The new packaging_tool.py file download path:
 
Link: https: //pan.baidu.com/s/1nMIrm5ArlUK6nB1xnJ8ptA Password: mwzp
After upgrading to 10.0.1 pip old version of pycharm use pip to install third-party libraries when it will error, error as shown above:

 

The main reason is the new pip changed some of the api which pip.main () instead pip_main (),

Legacy of pycharm referenced in packaging_tool.py in that pip.main () method, it will be an error.
The simplest, most perfect solution for:
1.找到pycharm 目录下的 \helper\packaging_tool.py 文件
2.用新版pycharm 的packaging_tool.py 替换 旧版 同名文件
ps:博主的pycharm是2017.2.4的 更老的版本 是否试用此方法 还有待尝试
 
新版packaging_tool.py文件下载路径为:
 
链接:https://pan.baidu.com/s/1nMIrm5ArlUK6nB1xnJ8ptA 密码:mwzp

Guess you like

Origin www.cnblogs.com/smallleiit/p/12297824.html
Recommended