相关疑难解决方法(0)

无法在 Python 3.9 上使用 Poetry 安装加密包

当我尝试poetry add cryptography在 Python 3.9.0 虚拟环境中使用 Python Poetry 1.1.4 包管理器 ( ) 安装加密模块时,我得到:

    error: can't find Rust compiler
    
    If you are using an outdated pip version, it is possible a prebuilt wheel is available for this package but pip is not able to install from it. Installing from the wheel would avoid the need for a Rust compiler.
    
    To update pip, run:
    
        pip install --upgrade pip
    
    and then retry package installation.
    
    If you did intend to build this …
Run Code Online (Sandbox Code Playgroud)

python-cryptography python-poetry

7
推荐指数
2
解决办法
2万
查看次数

无法在 Python-3.7-alpine docker 容器上安装 gcc

我正在尝试设置一个 Python docker 容器,当我运行命令“docker-compose up”来构建Dockerfile它时,它会在下面向我抛出此错误消息。

docker文件两周前就搭建成功了,我想到要重建docker容器,因为requirements.txt.

尝试构建映像会产生以下错误:

Collecting cryptography
  Downloading cryptography-2.8.tar.gz (504 kB)
  Installing build dependencies: started
  Installing build dependencies: finished with status 'error'
  ERROR: Command errored out with exit status 1:
   command: /usr/local/bin/python /usr/local/lib/python3.7/site-packages/pip install --ignore-installed --no-user --prefix /tmp/pip-build-env-6ilf25i_/overlay --no-warn-script-location --no-binary :none: --only-binary :none: -i https://pypi.org/simple -- 'setuptools>=40.6.0' wheel 'cffi>=1.8,!=1.11.3; platform_python_implementation != '"'"'PyPy'"'"''
       cwd: None
  Complete output (140 lines):
  Collecting setuptools>=40.6.0
    Downloading setuptools-46.0.0-py3-none-any.whl (582 kB)
  Collecting wheel
    Downloading wheel-0.34.2-py2.py3-none-any.whl (26 kB)
  Collecting cffi!=1.11.3,>=1.8
    Downloading cffi-1.14.0.tar.gz …
Run Code Online (Sandbox Code Playgroud)

python-3.x docker dockerfile

3
推荐指数
4
解决办法
1万
查看次数