ConnectTimeoutError when installing earthengine-api

263 Views Asked by At

I have pip 18.1 with python 3.6 and would like to install the earthengine-api so I typed pip install earthengine-api in a command prompt.

I got the following error message:

Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ConnectTimeoutError(<pip._vendor.urllib3.connection.VerifiedHTTPSConnection object at 0x06345BF0>, 'Connection to 10.168.209.72 timed out. (connect timeout=15)')': /simple/earthengine-api/ Could not find a version that satisfies the requirement earthengine-api (from versions: ) No matching distribution found for earthengine-api

I tried set | find "proxy" and it gave:

https_proxy=http://xx.xxx.xxx.xx:xxxx  
http_proxy=http://xx.xxx.xxx.xx:xxxx  
no_proxy=xxx.xxx.xxx.xx,xxx.0.0.1

while pip config list | find "proxy" gave:

FIND: Parameter format not correct

I don't understand the error message but suspected the protections of my work PC (of which I am not administrator) to be responsible for this issue, So I decided to install python on a home PC with
pip install earthengine-api
but in jupyter notebook I got "no module ee"
So I installed it with
conda install –c conda-forge earthengine-api
and now it works in jupyter (don't ask me why).

1

There are 1 best solutions below

2
droptop On

Your first installation of the earthengine-api package with pip installed the it as a system wide package, and probably not in a conda environment.

The python interpreter used by jupyter would I suppose be in the base environment of your conda installation, and so will only look for a requested package in that environment.

Try using conda to install your packages before resorting to pip. Checkout the guide here https://docs.conda.io/projects/conda/en/latest/user-guide/getting-started.html