pip install networkit error

不打扰是莪最后的温柔 提交于 2020-01-06 02:31:09

问题


I'm using the pip install networkit provide by the networkit homepage, but I don't know what's going wrong here, the terminal keep showing this:

Downloading/unpacking networkit
  Downloading networkit-3.4.1.tar.gz (582kB): 582kB downloaded
  Running setup.py (path:/private/var/folders/sy/lzckft690rn8xfm2f1svp8p00000gn/T/pip_build_runze/networkit/setup.py) egg_info for package networkit
    Traceback (most recent call last):
      File "<string>", line 17, in <module>
      File "/private/var/folders/sy/lzckft690rn8xfm2f1svp8p00000gn/T/pip_build_runze/networkit/setup.py", line 2, in <module>
        from setup_util import *
      File "setup_util.py", line 3, in <module>
        from subprocess import DEVNULL
    ImportError: cannot import name DEVNULL
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):

  File "<string>", line 17, in <module>

  File "/private/var/folders/sy/lzckft690rn8xfm2f1svp8p00000gn/T/pip_build_runze/networkit/setup.py", line 2, in <module>

    from setup_util import *

  File "setup_util.py", line 3, in <module>

    from subprocess import DEVNULL

ImportError: cannot import name DEVNULL

----------------------------------------
Cleaning up...
Command python setup.py egg_info failed with error code 1 in /private/var/folders/sy/lzckft690rn8xfm2f1svp8p00000gn/T/pip_build_runze/networkit
Storing debug log for failure in /Users/runze/.pip/pip.log

回答1:


Version you are trying to install is not compatible with version of python you are using.

It seems it made its way to python 3.3.something only - http://bugs.python.org/issue5870




回答2:


Using command "pip3 install networkit" would be fine. Don't forget add other libraries networkit needed to python3 modular.



来源:https://stackoverflow.com/questions/29004223/pip-install-networkit-error

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!