|
|
本帖最后由 skywing 于 2019-1-20 10:23 编辑
- root@localhost:~# pip install pysftp
- /usr/local/lib/python3.5/dist-packages/pip/_vendor/requests/__init__.py:83: RequestsDependencyWarning: Old version of cryptography ([1, 2, 3]) may cause slowdown.
- warnings.warn(warning, RequestsDependencyWarning)
- Collecting pysftp
- Downloading https://files.pythonhosted.org/packages/36/60/45f30390a38b1f92e0a8cf4de178cd7c2bc3f874c85430e40ccf99df8fe7/pysftp-0.2.9.tar.gz
- Collecting paramiko>=1.17 (from pysftp)
- Downloading https://files.pythonhosted.org/packages/cf/ae/94e70d49044ccc234bfdba20114fa947d7ba6eb68a2e452d89b920e62227/paramiko-2.4.2-py2.py3-none-any.whl (193kB)
- 100% |████████████████████████████████| 194kB 10.7MB/s
- Collecting pynacl>=1.0.1 (from paramiko>=1.17->pysftp)
- Downloading https://files.pythonhosted.org/packages/27/15/2cd0a203f318c2240b42cd9dd13c931ddd61067809fee3479f44f086103e/PyNaCl-1.3.0-cp34-abi3-manylinux1_x86_64.whl (759kB)
- 100% |████████████████████████████████| 768kB 16.4MB/s
- Collecting cryptography>=1.5 (from paramiko>=1.17->pysftp)
- Downloading https://files.pythonhosted.org/packages/60/c7/99b33c53cf3f20a97a4c4bfd3ab66dcc93d99da0a97cc9597aa36ae6bb62/cryptography-2.4.2-cp34-abi3-manylinux1_x86_64.whl (2.1MB)
- 100% |████████████████████████████████| 2.1MB 11.6MB/s
- Requirement already satisfied: pyasn1>=0.1.7 in /usr/lib/python3/dist-packages (from paramiko>=1.17->pysftp) (0.1.9)
- Collecting bcrypt>=3.1.3 (from paramiko>=1.17->pysftp)
- Downloading https://files.pythonhosted.org/packages/d0/79/79a4d167a31cc206117d9b396926615fa9c1fdbd52017bcced80937ac501/bcrypt-3.1.6-cp34-abi3-manylinux1_x86_64.whl (55kB)
- 100% |████████████████████████████████| 61kB 16.6MB/s
- Collecting cffi>=1.4.1 (from pynacl>=1.0.1->paramiko>=1.17->pysftp)
- Downloading https://files.pythonhosted.org/packages/59/cc/0e1635b4951021ef35f5c92b32c865ae605fac2a19d724fb6ff99d745c81/cffi-1.11.5-cp35-cp35m-manylinux1_x86_64.whl (420kB)
- 100% |████████████████████████████████| 430kB 19.2MB/s
- Requirement already satisfied: six in /usr/lib/python3/dist-packages (from pynacl>=1.0.1->paramiko>=1.17->pysftp) (1.10.0)
- Requirement already satisfied: idna>=2.1 in /usr/local/lib/python3.5/dist-packages (from cryptography>=1.5->paramiko>=1.17->pysftp) (2.7)
- Collecting asn1crypto>=0.21.0 (from cryptography>=1.5->paramiko>=1.17->pysftp)
- Downloading https://files.pythonhosted.org/packages/ea/cd/35485615f45f30a510576f1a56d1e0a7ad7bd8ab5ed7cdc600ef7cd06222/asn1crypto-0.24.0-py2.py3-none-any.whl (101kB)
- 100% |████████████████████████████████| 102kB 23.1MB/s
- Collecting pycparser (from cffi>=1.4.1->pynacl>=1.0.1->paramiko>=1.17->pysftp)
- Downloading https://files.pythonhosted.org/packages/68/9e/49196946aee219aead1290e00d1e7fdeab8567783e83e1b9ab5585e6206a/pycparser-2.19.tar.gz (158kB)
- 100% |████████████████████████████████| 163kB 22.4MB/s
- Building wheels for collected packages: pysftp, pycparser
- Running setup.py bdist_wheel for pysftp ... done
- Stored in directory: /root/.cache/pip/wheels/d4/53/02/181ea4f6c795b40c4f1d2022ba2ed15cf811d22975eb2e5968
- Running setup.py bdist_wheel for pycparser ... done
- Stored in directory: /root/.cache/pip/wheels/f2/9a/90/de94f8556265ddc9d9c8b271b0f63e57b26fb1d67a45564511
- Successfully built pysftp pycparser
- Installing collected packages: pycparser, cffi, pynacl, asn1crypto, cryptography, bcrypt, paramiko, pysftp
- Found existing installation: cryptography 1.2.3
- Uninstalling cryptography-1.2.3:
- Successfully uninstalled cryptography-1.2.3
- Successfully installed asn1crypto-0.24.0 bcrypt-3.1.6 cffi-1.11.5 cryptography-2.4.2 paramiko-2.4.2 pycparser-2.19 pynacl-1.3.0 pysftp-0.2.9
复制代码
安装pysftp没有报错,之后再运行任何pip命令都报这个错误,求mjj帮忙看下是哪里出了问题。
- root@localhost:~# pip list
- Traceback (most recent call last):
- File "/usr/local/bin/pip", line 7, in <module>
- from pip._internal import main
- File "/usr/local/lib/python3.5/dist-packages/pip/_internal/__init__.py", line 40, in <module>
- from pip._internal.cli.autocompletion import autocomplete
- File "/usr/local/lib/python3.5/dist-packages/pip/_internal/cli/autocompletion.py", line 8, in <module>
- from pip._internal.cli.main_parser import create_main_parser
- File "/usr/local/lib/python3.5/dist-packages/pip/_internal/cli/main_parser.py", line 12, in <module>
- from pip._internal.commands import (
- File "/usr/local/lib/python3.5/dist-packages/pip/_internal/commands/__init__.py", line 6, in <module>
- from pip._internal.commands.completion import CompletionCommand
- File "/usr/local/lib/python3.5/dist-packages/pip/_internal/commands/completion.py", line 6, in <module>
- from pip._internal.cli.base_command import Command
- File "/usr/local/lib/python3.5/dist-packages/pip/_internal/cli/base_command.py", line 18, in <module>
- from pip._internal.download import PipSession
- File "/usr/local/lib/python3.5/dist-packages/pip/_internal/download.py", line 15, in <module>
- from pip._vendor import requests, six, urllib3
- File "/usr/local/lib/python3.5/dist-packages/pip/_vendor/requests/__init__.py", line 97, in <module>
- from pip._vendor.urllib3.contrib import pyopenssl
- File "/usr/local/lib/python3.5/dist-packages/pip/_vendor/urllib3/contrib/pyopenssl.py", line 46, in <module>
- import OpenSSL.SSL
- File "/usr/lib/python3/dist-packages/OpenSSL/__init__.py", line 8, in <module>
- from OpenSSL import rand, crypto, SSL
- File "/usr/lib/python3/dist-packages/OpenSSL/SSL.py", line 118, in <module>
- SSL_ST_INIT = _lib.SSL_ST_INIT
- AttributeError: module 'lib' has no attribute 'SSL_ST_INIT'
复制代码 |
|