天天看點

【python】Could not install packages due to an EnvironmentError: [WinError 5] 拒絕通路等系列問題及解決方法

Could not install packages due to an EnvironmentError: [WinError 5] 拒絕通路等系列問題

起初是想對python裡面matplotlib進行下載下傳
方法一
Win+R輸入cmd進入到CMD視窗下,執行python -m pip install -U pip setuptools進行更新。      

方法一配置代碼截圖

【python】Could not install packages due to an EnvironmentError: [WinError 5] 拒絕通路等系列問題及解決方法
方法二
在Anaconda檔案路徑下執行pip install -U pip setuptools進行配置。      

方法二配置代碼截圖

【python】Could not install packages due to an EnvironmentError: [WinError 5] 拒絕通路等系列問題及解決方法
這裡就出現了Could not install packages due to an EnvironmentError: [WinError 5] 拒絕通路問題
  • 這裡就要使用 ’ --user ’ 權限去進行下載下傳
  • 重新在Anaconda裡打上pip install -U pip setuptools --user出現了Script file ‘E:\Anaconda\Scripts\pip-script.py’ is not present.問題
  • 這個是因為上面的upgrade操作已經把我的pip中的包或者是pip直接删掉了
  • 【python】Could not install packages due to an EnvironmentError: [WinError 5] 拒絕通路等系列問題及解決方法

解決方法

使用 easy_install pip
這個指令,重新安裝一下pip就好了      

解決方法配置代碼截圖

接下來就開始解決python裡面matplotlib進行下載下傳安裝問題

解決代碼截圖