Home > other >  PIP python beginners problems
PIP python beginners problems

Time:09-26

Want to install requests libraries as a result, I have been unsuccessful update PIP

CodePudding user response:

I have the administrator to update the PIP results still can't install the requests

CodePudding user response:

This is a network connection problem, it is ok to change the image source

CodePudding user response:

https://blog.csdn.net/ArkGod/article/details/81044462 this article should help you

CodePudding user response:

You need to: learn how to solve the problem
The problem is:
ReadTimeoutError HTTPSConnectionPool...
It means: network timeout
- "not you think the permissions problems
- "so: change the administrator of course useless
- "so the solution is: to find a way to not timeout
Implementation method:
1. After science and the Internet, and agent - "you can download properly not timeout
If not, consider reference:
Scientific knowledge summary online
Characteristics: a little bit of a problem, but once and for all, and is also applied to future technical data (such as Google search, etc.)

2. Replace the source
The PIP to download the address of the library without a website, by default, into a domestic some server
- "it soon there will be no connection timeout problems

How to change the source?
Refer to other people say
https://blog.csdn.net/ArkGod/article/details/81044462

Windows, to the root directory of the current user
Tend to be:
C: \ Users \ \ Administrator \
Or with your own C: \ Users \ YourUserName \

Then (if there is no new) editing PIP. Ini
Content is:

[global]
 
The index - url=https://pypi.tuna.tsinghua.edu.cn/simple


Or:

[global]
 
The index - url=https://pypi.tuna.tsinghua.edu.cn/simple

[install]
Trusted-host=pypi.tuna.tsinghua.edu.cn


The index of them - the value of the url can also be replaced by other, such as:

Ali cloud:

[global]
 
The index - url=http://mirrors.aliyun.com/pypi/simple/

[install]
Trusted-host=mirrors.aliyun.com


And the other:
Douban: http://pypi.douban.com

Reference:
/resolved to PIP replacement in Mac source to speed up the download



CodePudding user response:

PIP install * * * * * -i https://pypi.tuna.tsinghua.edu.cn/simple


* * * * fill in you want to load a package

CodePudding user response:

Python -m PIP install, upgrade PIP -i https://pypi.tuna.tsinghua.edu.cn/simple

Python -m PIP install, upgrade PIP - user - I https://pypi.tuna.tsinghua.edu.cn/simple
  • Related