python3.6 安装 paramiko 报错 ERROR: Could not build wheels for cryptography, which is required to instal

2023-05-13 15:25:29 浏览数 (3)

安装 paramiko 有个依赖 cryptography>=3.3,cryptography 需要大于 3.3 版本, python3.6 正常无法安装最新版 cryptography,故先安装 cryptography==3.4.8 版本再安装 paramiko。

代码语言:javascript复制
  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for cryptography
Failed to build cryptography
ERROR: Could not build wheels for cryptography, which is required to install pyproject.toml-based projects
代码语言:javascript复制
(flask_test) root@raspberrypi:~/yzq/flask_test# pip install cryptography==3.4.8
Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple, https://www.piwheels.org/simple
Collecting cryptography==3.4.8
  Downloading https://www.piwheels.org/simple/cryptography/cryptography-3.4.8-cp37-cp37m-linux_armv7l.whl (1.5 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.5/1.5 MB 215.3 kB/s eta 0:00:00
Requirement already satisfied: cffi>=1.12 in /root/.envs/flask_test/lib/python3.7/site-packages (from cryptography==3.4.8) (1.15.1)
Requirement already satisfied: pycparser in /root/.envs/flask_test/lib/python3.7/site-packages (from cffi>=1.12->cryptography==3.4.8) (2.21)
Installing collected packages: cryptography
  Attempting uninstall: cryptography
    Found existing installation: cryptography 3.1.1
    Uninstalling cryptography-3.1.1:
      Successfully uninstalled cryptography-3.1.1
Successfully installed cryptography-3.4.8
(flask_test) root@raspberrypi:~/yzq/flask_test# pip install paramiko
Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple, https://www.piwheels.org/simple
Collecting paramiko
  Using cached https://www.piwheels.org/simple/paramiko/paramiko-3.1.0-py3-none-any.whl (211 kB)
Collecting bcrypt>=3.2 (from paramiko)
  Using cached https://www.piwheels.org/simple/bcrypt/bcrypt-4.0.1-cp37-cp37m-linux_armv7l.whl (609 kB)
Requirement already satisfied: cryptography>=3.3 in /root/.envs/flask_test/lib/python3.7/site-packages (from paramiko) (3.4.8)
Collecting pynacl>=1.5 (from paramiko)
  Using cached https://www.piwheels.org/simple/pynacl/PyNaCl-1.5.0-cp37-cp37m-linux_armv7l.whl (594 kB)
Requirement already satisfied: cffi>=1.12 in /root/.envs/flask_test/lib/python3.7/site-packages (from cryptography>=3.3->paramiko) (1.15.1)
Requirement already satisfied: pycparser in /root/.envs/flask_test/lib/python3.7/site-packages (from cffi>=1.12->cryptography>=3.3->paramiko) (2.21)
Installing collected packages: bcrypt, pynacl, paramiko
Successfully installed bcrypt-4.0.1 paramiko-3.1.0 pynacl-1.5.0

0 人点赞