天天看點

python pip 安裝 逾時 ReadTimeoutError 換源

pip._vendor.requests.packages.urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='files.pythonhosted.org', port=443): Read timed out.

解決辦法

pip install --upgrade networkx --default-timeout=1000

若還是無法下載下傳,可更換源,添加-i選項

pip install -U scikit-fuzzy -i https://pypi.tuna.tsinghua.edu.cn/simple/
           

常見的源

清華大學 https://pypi.tuna.tsinghua.edu.cn/simple/

中國科學技術大學 http://pypi.mirrors.ustc.edu.cn/simple/

阿裡雲 http://mirrors.aliyun.com/pypi/simple/

永久切換:在c/user/XX中,找到 .condarc檔案,進行修改

channels:
  - https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
  - defaults
show_channel_urls: true
ssl_verify: true