Pyhton pip install is failing... is it firewall?

:uk:/:us: Message template (english)

My YunoHost server

Hardware: contabo . com VPS, 8GB RAM
YunoHost version: 3.6.5.3 (stable)
I have access to my server : Through SSH and webadmin
Are you in a special context or did you perform some particular tweaking on your YunoHost instance ? : no

Description of my issue

On my server where I have yunohost installed (it’s a hosted VPS) I’m trying to install some unrelated application which has pip dependencies but it is failing:

pip install -r requirements.txt
WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.VerifiedHTTPSConnection object at 0x7f2378f3da50>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution')': /simple/prompt-toolkit/
WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.VerifiedHTTPSConnection object at 0x7f2378f744d0>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution')': /simple/prompt-toolkit/
WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.VerifiedHTTPSConnection object at 0x7f2378f74c50>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution')': /simple/prompt-toolkit/
WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.VerifiedHTTPSConnection object at 0x7f2378f74b50>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution')': /simple/prompt-toolkit/
WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.VerifiedHTTPSConnection object at 0x7f2378f74d10>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution')': /simple/prompt-toolkit/
ERROR: Could not find a version that satisfies the requirement prompt_toolkit (from -r requirements.txt (line 1)) (from versions: none)
ERROR: No matching distribution found for prompt_toolkit (from -r requirements.txt (line 1))
The command '/bin/sh -c pip install -r requirements.txt' returned a non-zero code: 1
Makefile:9: recipe for target 'config' failed
make: *** [config] Error 1

I suspect pip is failing to leave yunohost firewall… but I’m not sure how to solve this. I wonder if anyone else had similar trouble and solved it somehow.

Temporary failure in name resolution

=> you may have a dns resolver issue. Check you can ping wikipedia.org and ping6 wikipedia.org . If no, check service dnsmasq is up via webadmin or via:

systemctl status dnsmasq

If its down try to restart it via webadmin or via:

systemctl restart dnsmasq

Important: you shouldn’t run pip directly on your system, you should run it inside a python virtualenv. If you run it directly on your system, it could break some things in your system.