How to fix this error [SSL: TLSV1_ALERT_PROTOCOL_VERSION] when install python packages

  • A+
Category:Languages

I am trying to install python library using pip, getting ssl error.

~/projects/base  pre-master±  pip install xdict

Collecting xdict
  Could not fetch URL https://pypi.python.org/simple/xdict/: There was a problem confirming the ssl certificate: [SSL: TLSV1_ALERT_PROTOCOL_VERSION] tlsv1 alert protocol version (_ssl.c:590) - skipping
  Could not find a version that satisfies the requirement xdict (from versions: )
No matching distribution found for xdict

pip version: pip 9.0.1

Any idea how to fix this error ?

 


Try to upgrade pip as follows:

curl https://bootstrap.pypa.io/get-pip.py | python 

Note: You may need to use sudo python above if not in a virtual environment.

Your issue seems to be related to the recent TLS deprecation for pip.

Comment

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen: