首页 > 解决方案 > pip-review :: 错误:命令出错,退出状态为 1:

问题描述

我想更新所有 Python 模块。

在 StackOverflow 上,我在此页面上找到了我认为最好的解决方案。

不幸的是,如果我运行:

$ pip install pip-review
$ pip-review --local --interactive

Python 工作了几分钟,下载并收集模块更新,然后完全失败并出现错误:

    ERROR: Command errored out with exit status 1:
     command: /usr/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-p9q7aft7/tables/setup.py'"'"'; __file__='"'"'/tmp/pip-install-p9q7aft7/tables/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-install-p9q7aft7/tables/pip-egg-info
         cwd: /tmp/pip-install-p9q7aft7/tables/
    Complete output (15 lines):
    /tmp/H5closecy5usdpw.c:1:1: warning: return type defaults to ‘int’ [-Wimplicit-int]
     main (int argc, char **argv) {
     ^
    /tmp/H5closecy5usdpw.c: In function ‘main’:
    /tmp/H5closecy5usdpw.c:2:5: warning: implicit declaration of function ‘H5close’ [-Wimplicit-function-declaration]
         H5close();
         ^
    /usr/bin/ld: cannot find -lhdf5
    collect2: error: ld returned 1 exit status
    * Using Python 3.5.2 (default, Oct  8 2019, 13:06:37)
    * USE_PKGCONFIG: True
    .. ERROR:: Could not find a local HDF5 installation.
       You may need to explicitly state where your local HDF5 headers and
       library can be found by setting the ``HDF5_DIR`` environment
       variable or by using the ``--hdf5`` command-line option.
    ----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

我搜索了这个错误,但它对我来说似乎是一个普遍的错误,我不知道应该采取什么方向来调试这个问题。

标签: python-3.xmodulepip

解决方案


推荐阅读