【问题标题】:Python Flask Install - Are these errors bad?Python Flask 安装 - 这些错误是否严重?
【发布时间】:2018-05-14 06:53:58
【问题描述】:

安装 Flask 时出现错误,但仍然显示成功。这些错误会给我带来麻烦吗?

在 Debian 9 上使用 Python3

我尝试升级 setuptools,但仍然遇到相同的错误。

Collecting flask
  Using cached Flask-0.12.2-py2.py3-none-any.whl
Collecting itsdangerous>=0.21 (from flask)
  Using cached itsdangerous-0.24.tar.gz
Collecting Werkzeug>=0.7 (from flask)
  Using cached Werkzeug-0.12.2-py2.py3-none-any.whl
Collecting click>=2.0 (from flask)
  Using cached click-6.7-py2.py3-none-any.whl
Collecting Jinja2>=2.4 (from flask)
  Using cached Jinja2-2.10-py2.py3-none-any.whl
Collecting MarkupSafe>=0.23 (from Jinja2>=2.4->flask)
  Using cached MarkupSafe-1.0.tar.gz
Building wheels for collected packages: itsdangerous, MarkupSafe
  Running setup.py bdist_wheel for itsdangerous ... error
  Complete output from command /home/ev/Desktop/DNIT/venv/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-blrz3kyb/itsdangerous/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /tmp/tmprpoc62sipip-wheel- --python-tag cp35:
  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 itsdangerous
  Running setup.py clean for itsdangerous
  Running setup.py bdist_wheel for MarkupSafe ... error
  Complete output from command /home/ev/Desktop/DNIT/venv/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-blrz3kyb/MarkupSafe/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /tmp/tmp8419jrrypip-wheel- --python-tag cp35:
  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 MarkupSafe
  Running setup.py clean for MarkupSafe
Failed to build itsdangerous MarkupSafe
Installing collected packages: itsdangerous, Werkzeug, click, MarkupSafe, Jinja2, flask
  Running setup.py install for itsdangerous ... done
  Running setup.py install for MarkupSafe ... done
Successfully installed Jinja2-2.10 MarkupSafe-1.0 Werkzeug-0.12.2 click-6.7 flask-0.12.2 itsdangerous-0.24

【问题讨论】:

  • 尝试安装 debian 软件包 python-wheel 并重试您的 pip install flask 命令
  • 当你使用python3时,你必须安装python3-wheel。
  • 表示已安装完毕并使用最新版本。不过谢谢!
  • 我很抱歉,这确实是正确的答案。我对另一个项目感到过度疲劳。非常感谢你!太棒了!

标签: python pip python-wheel


【解决方案1】:

这就是解决问题的方法

pip install wheel 

您可以删除 venv 文件夹并像这样重新启动

python3 -m venv ./venv 

pip install wheel 
pip install flask 

这样就可以解决问题了

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2022-01-21
    • 1970-01-01
    • 1970-01-01
    • 2017-12-13
    • 2014-08-30
    • 1970-01-01
    • 2020-10-11
    • 1970-01-01
    相关资源
    最近更新 更多