1

嗨,我一直在尝试将密码学安装到我的 venv 中,但我的 venv 没有找到'bdist_wheel'. (Python3)

wheel像这样安装pip install --user wheel并尝试安装加密我在 setup.py 脚本期间pip install --user cryptography收到此错误。error: invalid command 'bdist_wheel'我也试过pip install --upgrade setuptools

我错过了什么?我在这里看到过类似的 QA,但似乎没有出现在 venv 中。

pip install --user cryptography

Collecting cryptography
  Using cached https://files.pythonhosted.org/packages/ec/b2/faa78c1ab928d2b2c634c8b41ff1181f0abdd9adf9193211bd606ffa57e2/cryptography-2.2.2.tar.gz
Collecting idna>=2.1 (from cryptography)
  Using cached https://files.pythonhosted.org/packages/27/cc/6dd9a3869f15c2edfab863b992838277279ce92663d334df9ecf5106f5c6/idna-2.6-py2.py3-none-any.whl
Collecting asn1crypto>=0.21.0 (from cryptography)
  Using cached https://files.pythonhosted.org/packages/ea/cd/35485615f45f30a510576f1a56d1e0a7ad7bd8ab5ed7cdc600ef7cd06222/asn1crypto-0.24.0-py2.py3-none-any.whl
Collecting six>=1.4.1 (from cryptography)
  Using cached https://files.pythonhosted.org/packages/67/4b/141a581104b1f6397bfa78ac9d43d8ad29a7ca43ea90a2d863fe3056e86a/six-1.11.0-py2.py3-none-any.whl
Collecting cffi>=1.7 (from cryptography)
  Using cached https://files.pythonhosted.org/packages/59/cc/0e1635b4951021ef35f5c92b32c865ae605fac2a19d724fb6ff99d745c81/cffi-1.11.5-cp35-cp35m-manylinux1_x86_64.whl
Collecting pycparser (from cffi>=1.7->cryptography)
Building wheels for collected packages: cryptography
  Running setup.py bdist_wheel for cryptography ... error
  Complete output from command /usr/local/virtualenvs/profiles_api/profiles_api3/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-2sa4x5ab/cryptography/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" bdist_wheel -d /tmp/tmplvmgp_y8pip-wheel- --python-tag cp35:

  Installed /tmp/pip-build-2sa4x5ab/cryptography/.eggs/cffi-1.11.5-py3.5-linux-x86_64.egg
  Searching for pycparser
  Reading https://pypi.python.org/simple/pycparser/
  Best match: pycparser 2.18
  Downloading https://files.pythonhosted.org/packages/8c/2d/aad7f16146f4197a11f8e91fb81df177adcc2073d36a17b1491fd09df6ed/pycparser-2.18.tar.gz#sha256=99a8ca03e29851d96616ad0404b4aad7d9ee16f25c9f9708a11faf2810f7b226
  Processing pycparser-2.18.tar.gz
  Writing /tmp/easy_install-_vc_2z13/pycparser-2.18/setup.cfg
  Running pycparser-2.18/setup.py -q bdist_egg --dist-dir /tmp/easy_install-_vc_2z13/pycparser-2.18/egg-dist-tmp-omz1wtad
  warning: no previously-included files matching 'yacctab.*' found under directory 'tests'
  warning: no previously-included files matching 'lextab.*' found under directory 'tests'
  warning: no previously-included files matching 'yacctab.*' found under directory 'examples'
  warning: no previously-included files matching 'lextab.*' found under directory 'examples'
  zip_safe flag not set; analyzing archive contents...
  pycparser.ply.__pycache__.lex.cpython-35: module references __file__
  pycparser.ply.__pycache__.lex.cpython-35: module MAY be using inspect.getsourcefile
  pycparser.ply.__pycache__.ygen.cpython-35: module references __file__
  pycparser.ply.__pycache__.yacc.cpython-35: module references __file__
  pycparser.ply.__pycache__.yacc.cpython-35: module MAY be using inspect.getsourcefile
  pycparser.ply.__pycache__.yacc.cpython-35: module MAY be using inspect.stack
  creating /tmp/pip-build-2sa4x5ab/cryptography/.eggs/pycparser-2.18-py3.5.egg
  Extracting pycparser-2.18-py3.5.egg to /tmp/pip-build-2sa4x5ab/cryptography/.eggs

  Installed /tmp/pip-build-2sa4x5ab/cryptography/.eggs/pycparser-2.18-py3.5.egg
  /usr/lib/python3.5/distutils/dist.py:261: UserWarning: Unknown distribution option: 'python_requires'
    warnings.warn(msg)
  usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
     or: -c --help [cmd1 cmd2 ...]
     or: -c --help-commands
     or: -c cmd --help

  error: invalid command 'bdist_wheel'

  ----------------------------------------
  Failed building wheel for cryptography
  Running setup.py clean for cryptography
Failed to build cryptography
Installing collected packages: idna, asn1crypto, six, pycparser, cffi, cryptography
  Running setup.py install for cryptography ... done
Successfully installed asn1crypto cffi cryptography idna pycparser six
4

0 回答 0