当我运行pip install CryptContext
或pip install ssl
命令时,我得到以下消息:
Downloading/unpacking ssl
Cannot fetch index base URL https://pypi.python.org/simple/
Could not find any downloads that satisfy the requirement ssl
Cleaning up...
No distributions at all found for ssl
Storing debug log for failure in /Users/chauncey/.pip/pip.log
Chaunceys-MacBook-Pro-2:dist chauncey$ pip install CryptContext
Downloading/unpacking CryptContext
Cannot fetch index base URL https://pypi.python.org/simple/
Could not find any downloads that satisfy the requirement CryptContext
Cleaning up...
No distributions at all found for CryptContext
Storing debug log for failure in /Users/chauncey/.pip/pip.log
当我查看pip.log
文件时,我得到以下信息:
/Library/Frameworks/Python.framework/Versions/2.7/bin/pip run on Sun Dec 1 20:45:23 2019
Downloading/unpacking CryptContext
Getting page https://pypi.python.org/simple/CryptContext/
Could not fetch URL https://pypi.python.org/simple/CryptContext/: connection error: [SSL: TLSV1_ALERT_PROTOCOL_VERSION] tlsv1 alert protocol version (_ssl.c:581)
Will skip URL https://pypi.python.org/simple/CryptContext/ when looking for download links for CryptContext
Getting page https://pypi.python.org/simple/
Could not fetch URL https://pypi.python.org/simple/: connection error: HTTPSConnectionPool(host='pypi.python.org', port=443): Max retries exceeded with url: /simple/ (Caused by <class 'httplib.CannotSendRequest'>: )
Will skip URL https://pypi.python.org/simple/ when looking for download links for CryptContext
Cannot fetch index base URL https://pypi.python.org/simple/
URLs to search for versions for CryptContext:
* https://pypi.python.org/simple/CryptContext/
Getting page https://pypi.python.org/simple/CryptContext/
Could not fetch URL https://pypi.python.org/simple/CryptContext/: connection error: [SSL: TLSV1_ALERT_PROTOCOL_VERSION] tlsv1 alert protocol version (_ssl.c:581)
Will skip URL https://pypi.python.org/simple/CryptContext/ when looking for download links for CryptContext
Could not find any downloads that satisfy the requirement CryptContext
我把范围缩小到这一行:
Could not fetch URL https://pypi.python.org/simple/CryptContext/: connection error: [SSL: TLSV1_ALERT_PROTOCOL_VERSION] tlsv1 alert protocol version (_ssl.c:581)
然后我运行以下命令:
sudo mv /usr/bin/openssl /usr/bin/openssl_old
sudo ln -s /usr/local/Cellar/openssl/1.0.2g/bin/openssl /usr/bin/openssl
在此之后,我运行openssl version -a
并得到以下结果:
OpenSSL 1.0.2g 1 Mar 2016
built on: reproducible build, date unspecified
platform: darwin64-x86_64-cc
options: bn(64,64) rc4(ptr,int) des(idx,cisc,16,int) idea(int) blowfish(idx)
compiler: clang -I. -I.. -I../include -fPIC -fno-common -DOPENSSL_PIC -DZLIB_SHARED -DZLIB -DOPENSSL_THREADS -D_REENTRANT -DDSO_DLFCN -DHAVE_DLFCN_H -arch x86_64 -O3 -DL_ENDIAN -Wall -DOPENSSL_IA32_SSE2 -DOPENSSL_BN_ASM_MONT -DOPENSSL_BN_ASM_MONT5 -DOPENSSL_BN_ASM_GF2m -DSHA1_ASM -DSHA256_ASM -DSHA512_ASM -DMD5_ASM -DAES_ASM -DVPAES_ASM -DBSAES_ASM -DWHIRLPOOL_ASM -DGHASH_ASM -DECP_NISTZ256_ASM
OPENSSLDIR: "/usr/local/etc/openssl"
但是,当我检查pip.log
文件时,他们仍然在说上面指定的相同错误。你知道吗
我的Mac电脑很旧了。是Version 10.7.6
。你知道吗
目前没有回答
相关问题 更多 >
编程相关推荐