当我尝试安装鳗鱼时,出现此错误

时间:2020-01-30 20:19:42

标签: python python-3.x eel

错误:命令错误,退出状态为1: 命令:'c:\ users \ hp \ appdata \ local \ programs \ python \ python38-32 \ python.exe'-c'import sys,setuptools,tokenize; sys.argv [0] ='“'”'C:\ Users \ HP \ AppData \ Local \ Temp \ pip-install-8kpybrip \ gevent \ setup.py'“'”'; 文件 ='“'”'C:\ Users \ HP \ AppData \ Local \ Temp \ pip-install-8kpybrip \ gevent \ setup.py'“'” ;; f = getattr(tokenize, '“”“'open'”'“,打开)(文件); code = f.read()。replace('”'“'\ r \ n'”'“', '“'”'\ n'“'”'); f.close(); exec(compile(code, file ,'“'”'exec'“'”')))'egg_info --egg-base'C:\ Users \ HP \ AppData \ Local \ Temp \ pip-install-8kpybrip \ gevent \ pip-egg-info' CWD:C:\ Users \ HP \ AppData \ Local \ Temp \ pip-install-8kpybrip \ gevent \ 完整输出(113行): 追溯(最近一次通话): _find_latest_available_vc_ver中的文件“ c:\ users \ hp \ appdata \ local \ programs \ python \ python38-32 \ lib \ site-packages \ setuptools \ msvc.py”,行489 返回self.find_available_vc_vers()[-1] IndexError:列表索引超出范围

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 154, in save_modules
    yield saved
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 195, in setup_context
    yield
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 250, in run_setup
    _execfile(setup_script, ns)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 45, in _execfile
    exec(code, globals, locals)
  File "C:\Users\HP\AppData\Local\Temp\easy_install-1l4v3s5z\cffi-1.13.2\setup.py", line 127, in <module>
    HUB_PRIMITIVES = Extension(name="gevent.__hub_primitives",
  File "C:\Users\HP\AppData\Local\Temp\easy_install-1l4v3s5z\cffi-1.13.2\setup.py", line 105, in uses_msvc
    include_dirs=include_dirs)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\distutils\command\config.py", line 225, in try_compile
    self._compile(body, headers, include_dirs, lang)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\distutils\command\config.py", line 132, in _compile
    self.compiler.compile([src], include_dirs=include_dirs)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\distutils\_msvccompiler.py", line 360, in compile
    self.initialize()
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\distutils\_msvccompiler.py", line 253, in initialize
    vc_env = _get_vc_env(plat_spec)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\msvc.py", line 185, in msvc14_get_vc_env
    return EnvironmentInfo(plat_spec, vc_min_ver=14.0).return_env()
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\msvc.py", line 843, in __init__
    self.si = SystemInfo(self.ri, vc_ver)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\msvc.py", line 485, in __init__
    self.vc_ver = vc_ver or self._find_latest_available_vc_ver()
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\msvc.py", line 492, in _find_latest_available_vc_ver
    raise distutils.errors.DistutilsPlatformError(err)
distutils.errors.DistutilsPlatformError: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": https://visualstudio.microsoft.com/downloads/

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "C:\Users\HP\AppData\Local\Temp\pip-install-8kpybrip\gevent\setup.py", line 427, in <module>
    run_setup(EXT_MODULES, run_make=_BUILDING)
  File "C:\Users\HP\AppData\Local\Temp\pip-install-8kpybrip\gevent\setup.py", line 328, in run_setup
    setup(
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\__init__.py", line 144, in setup
    _install_setup_requires(attrs)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\__init__.py", line 139, in _install_setup_requires
    dist.fetch_build_eggs(dist.setup_requires)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\dist.py", line 716, in fetch_build_eggs
    resolved_dists = pkg_resources.working_set.resolve(
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\pkg_resources\__init__.py", line 780, in resolve
    dist = best[req.key] = env.best_match(
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\pkg_resources\__init__.py", line 1065, in best_match
    return self.obtain(req, installer)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\pkg_resources\__init__.py", line 1077, in obtain
    return installer(requirement)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\dist.py", line 786, in fetch_build_egg
    return cmd.easy_install(req)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\easy_install.py", line 679, in easy_install
    return self.install_item(spec, dist.location, tmpdir, deps)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\easy_install.py", line 705, in install_item
    dists = self.install_eggs(spec, download, tmpdir)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\easy_install.py", line 890, in install_eggs
    return self.build_and_install(setup_script, setup_base)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\easy_install.py", line 1158, in build_and_install
    self.run_setup(setup_script, setup_base, args)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\easy_install.py", line 1144, in run_setup
    run_setup(setup_script, args)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 253, in run_setup
    raise
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\contextlib.py", line 131, in __exit__
    self.gen.throw(type, value, traceback)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 195, in setup_context
    yield
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\contextlib.py", line 131, in __exit__
    self.gen.throw(type, value, traceback)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 166, in save_modules
    saved_exc.resume()
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 141, in resume
    six.reraise(type, exc, self._tb)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\_vendor\six.py", line 685, in reraise
    raise value.with_traceback(tb)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 154, in save_modules
    yield saved
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 195, in setup_context
    yield
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 250, in run_setup
    _execfile(setup_script, ns)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 45, in _execfile
    exec(code, globals, locals)
  File "C:\Users\HP\AppData\Local\Temp\easy_install-1l4v3s5z\cffi-1.13.2\setup.py", line 127, in <module>
    HUB_PRIMITIVES = Extension(name="gevent.__hub_primitives",
  File "C:\Users\HP\AppData\Local\Temp\easy_install-1l4v3s5z\cffi-1.13.2\setup.py", line 105, in uses_msvc
    include_dirs=include_dirs)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\distutils\command\config.py", line 225, in try_compile
    self._compile(body, headers, include_dirs, lang)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\distutils\command\config.py", line 132, in _compile
    self.compiler.compile([src], include_dirs=include_dirs)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\distutils\_msvccompiler.py", line 360, in compile
    self.initialize()
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\distutils\_msvccompiler.py", line 253, in initialize
    vc_env = _get_vc_env(plat_spec)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\msvc.py", line 185, in msvc14_get_vc_env
    return EnvironmentInfo(plat_spec, vc_min_ver=14.0).return_env()
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\msvc.py", line 843, in __init__
    self.si = SystemInfo(self.ri, vc_ver)
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\msvc.py", line 485, in __init__
    self.vc_ver = vc_ver or self._find_latest_available_vc_ver()
  File "c:\users\hp\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\msvc.py", line 492, in _find_latest_available_vc_ver
    raise distutils.errors.DistutilsPlatformError(err)
distutils.errors.DistutilsPlatformError: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": https://visualstudio.microsoft.com/downloads/
----------------------------------------

错误:命令错误,退出状态为1:python setup.py egg_info检查日志以获取完整的命令输出。

1 个答案:

答案 0 :(得分:-1)

您可以在代码输出中看到实际答案:

distutils.errors.DistutilsPlatformError: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": https://visualstudio.microsoft.com/downloads/

Microsoft Visual Studio->只需下载构建工具,而不是整个IDE。