Since the in-house developed environment is connected to the network via a proxy server, Every time I get a network error.
For example, if you simply execute pip at runtime, Retrying will be repeated as follows.
C:\Users\thithi7110>pip install webdriver_manager Collecting webdriver_manager Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ConnectTimeoutError(, 'Connection to pypi.python.org timed out. (connect timeout=15)')': /simple/webdriver-manager/ Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ConnectTimeoutError( , 'Connection to pypi.python.org timed out. (connect timeout=15)')': /simple/webdriver-manager/ Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ConnectTimeoutError( , 'Connection to pypi.python.org timed out. (connect timeout=15)')': /simple/webdriver-manager/ Operation cancelled by user
So at runtime
--proxy =
C:\Users\thithi7110>pip install webdriver_manager --proxy=proxy.hoge.co.jp:8080
Collecting webdriver_manager
Downloading https://files.pythonhosted.org/packages/dd/3c/2e2d71aeb28ee73ecaf12b545542b082ca81c8c091bb05028c52c42696ce/webdriver_manager-2.4.0-py2.py3-none-any.whl
Collecting crayons (from webdriver_manager)
Downloading https://files.pythonhosted.org/packages/5b/0d/e3fad4ca1de8e70e06444e7d777a5984261e1db98758b5be3e8296c03fe9/crayons-0.4.0-py2.py3-none-any.whl
Collecting requests (from webdriver_manager)
The download has started successfully.
When running python, like this: I ran pytho after setting http_proxy and https_proxy and it worked.
set http_proxy=http://proxy.hoge.co.jp:8080 set https_proxy=https://proxy.hoge.co.jp:8080
hoge.bat
rem proxy settings
set http_proxy=http://proxy.hoge.co.jp:8080
set https_proxy=https://proxy.hoge.co.jp:8080
python "fugafuga.py"
Recommended Posts