Kivy: 在 python 3.8.0 上安装 kivy

创建于 2019-10-21  ·  12评论  ·  资料来源: kivy/kivy

嗨,我将我的 python 版本更新为 3.8.0,当我尝试安装 kivy 时,出现以下错误“当我尝试在 pycharm 上安装它时也发生了错误”:

C:\Users\Hussam>pip install Kivy
Collecting Kivy
  Using cached https://files.pythonhosted.org/packages/1b/4d/3f8a720f561dc1eabe036c0d87c6ce9d02823275391265538e606f45e37a/Kivy-1.11.1.tar.gz
    ERROR: Command errored out with exit status 1:
     command: 'c:\users\hussam\appdata\local\programs\python\python38\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\Hussam\\AppData\\Local\\Temp\\pip-install-wmjvsmt5\\Kivy\\setup.py'"'"'; __file__='"'"'C:\\Users\\Hussam\\AppData\\Local\\Temp\\pip-install-wmjvsmt5\\Kivy\\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 'C:\Users\Hussam\AppData\Local\Temp\pip-install-wmjvsmt5\Kivy\pip-egg-info'
         cwd: C:\Users\Hussam\AppData\Local\Temp\pip-install-wmjvsmt5\Kivy\
    Complete output (199 lines):
    Using setuptools
    User distribution detected, avoid portable command.
    Using this graphics system: OpenGL
    WARNING: A problem occurred while running pkg-config --libs --cflags gstreamer-1.0 (code 1)


    b"'pkg-config' is not recognized as an internal or external command,\r\noperable program or batch file.\r\n"


    WARNING: A problem occurred while running pkg-config --libs --cflags gstreamer-1.0 (code 1)


    b"'pkg-config' is not recognized as an internal or external command,\r\noperable program or batch file.\r\n"


    WARNING: A problem occurred while running pkg-config --libs --cflags sdl2 SDL2_ttf SDL2_image SDL2_mixer (code 1)


    b"'pkg-config' is not recognized as an internal or external command,\r\noperable program or batch file.\r\n"


    ERROR: Dependency for context.pyx not resolved: config.pxi
    ERROR: Dependency for compiler.pyx not resolved: config.pxi
    ERROR: Dependency for context_instructions.pyx not resolved: config.pxi
    ERROR: Dependency for fbo.pyx not resolved: config.pxi
    ERROR: Dependency for gl_instructions.pyx not resolved: config.pxi
    ERROR: Dependency for instructions.pyx not resolved: config.pxi
    ERROR: Dependency for opengl.pyx not resolved: config.pxi
    ERROR: Dependency for opengl_utils.pyx not resolved: config.pxi
    ERROR: Dependency for shader.pyx not resolved: config.pxi
    ERROR: Dependency for stencil_instructions.pyx not resolved: config.pxi
    ERROR: Dependency for scissor_instructions.pyx not resolved: config.pxi
    ERROR: Dependency for texture.pyx not resolved: config.pxi
    ERROR: Dependency for vbo.pyx not resolved: config.pxi
    ERROR: Dependency for vertex.pyx not resolved: config.pxi
    ERROR: Dependency for vertex_instructions.pyx not resolved: config.pxi
    ERROR: Dependency for cgl.pyx not resolved: config.pxi
    ERROR: Dependency for cgl_mock.pyx not resolved: config.pxi
    ERROR: Dependency for cgl_gl.pyx not resolved: config.pxi
    ERROR: Dependency for cgl_glew.pyx not resolved: config.pxi
    ERROR: Dependency for cgl_sdl2.pyx not resolved: config.pxi
    ERROR: Dependency for svg.pyx not resolved: config.pxi
    Compiling C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\Cython\Plex\Scanners.py because it changed.
    Compiling C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\Cython\Plex\Actions.py because it changed.
    Compiling C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\Cython\Compiler\Scanning.py because it changed.
    Compiling C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\Cython\Compiler\Visitor.py because it changed.
    Compiling C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\Cython\Compiler\FlowControl.py because it changed.
    Compiling C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\Cython\Runtime\refnanny.pyx because it changed.
    Compiling C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\Cython\Compiler\FusedNode.py because it changed.
    Compiling C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\Cython\Tempita\_tempita.py because it changed.
    [1/8] Cythonizing C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\Cython\Compiler\FlowControl.py
    [2/8] Cythonizing C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\Cython\Compiler\FusedNode.py
    [3/8] Cythonizing C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\Cython\Compiler\Scanning.py
    [4/8] Cythonizing C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\Cython\Compiler\Visitor.py
    [5/8] Cythonizing C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\Cython\Plex\Actions.py
    [6/8] Cythonizing C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\Cython\Plex\Scanners.py
    [7/8] Cythonizing C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\Cython\Runtime\refnanny.pyx
    [8/8] Cythonizing C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\Cython\Tempita\_tempita.py
     Unable to find pgen, not compiling formal grammar.
     warning: no files found matching 'Doc\*'
     warning: no files found matching '*.pyx' under directory 'Cython\Debugger\Tests'
     warning: no files found matching '*.pxd' under directory 'Cython\Debugger\Tests'
     warning: no files found matching '*.pxd' under directory 'Cython\Utility'
     warning: no files found matching 'pyximport\README'
     Traceback (most recent call last):
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\msvc.py", line 489, in _find_latest_available_vc_ver
         return self.find_available_vc_vers()[-1]
     IndexError: list index out of range


     During handling of the above exception, another exception occurred:


     Traceback (most recent call last):
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\distutils\core.py", line 148, in setup
         dist.run_commands()
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\distutils\dist.py", line 966, in run_commands
         self.run_command(cmd)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\distutils\dist.py", line 985, in run_command
         cmd_obj.run()
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\command\bdist_egg.py", line 172, in run
         cmd = self.call_command('install_lib', warn_dir=0)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\command\bdist_egg.py", line 158, in call_command
         self.run_command(cmdname)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\distutils\cmd.py", line 313, in run_command
         self.distribution.run_command(command)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\distutils\dist.py", line 985, in run_command
         cmd_obj.run()
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\command\install_lib.py", line 11, in run
         self.build()
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\distutils\command\install_lib.py", line 107, in build
         self.run_command('build_ext')
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\distutils\cmd.py", line 313, in run_command
         self.distribution.run_command(command)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\distutils\dist.py", line 985, in run_command
         cmd_obj.run()
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\command\build_ext.py", line 84, in run
         _build_ext.run(self)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\distutils\command\build_ext.py", line 340, in run
         self.build_extensions()
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\distutils\command\build_ext.py", line 449, in build_extensions
         self._build_extensions_serial()
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\distutils\command\build_ext.py", line 474, in _build_extensions_serial
         self.build_extension(ext)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\command\build_ext.py", line 205, in build_extension
         _build_ext.build_extension(self, ext)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\distutils\command\build_ext.py", line 528, in build_extension
         objects = self.compiler.compile(sources,
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\distutils\_msvccompiler.py", line 360, in compile
         self.initialize()
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\distutils\_msvccompiler.py", line 253, in initialize
         vc_env = _get_vc_env(plat_spec)
       File "c:\users\hussam\appdata\local\programs\python\python38\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\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\msvc.py", line 843, in __init__
         self.si = SystemInfo(self.ri, vc_ver)
       File "c:\users\hussam\appdata\local\programs\python\python38\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\hussam\appdata\local\programs\python\python38\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 "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\sandbox.py", line 154, in save_modules
         yield saved
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\sandbox.py", line 195, in setup_context
         yield
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\sandbox.py", line 250, in run_setup
         _execfile(setup_script, ns)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\sandbox.py", line 45, in _execfile
         exec(code, globals, locals)
       File "C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\setup.py", line 228, in <module>
         This version of Cython is untested with Kivy. While this version may
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\__init__.py", line 145, in setup
         return distutils.core.setup(**attrs)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\distutils\core.py", line 163, in setup
         raise SystemExit("error: " + str(msg))
     SystemExit: error: 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 "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\command\easy_install.py", line 1144, in run_setup
         run_setup(setup_script, args)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\sandbox.py", line 253, in run_setup
         raise
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\contextlib.py", line 131, in __exit__
         self.gen.throw(type, value, traceback)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\sandbox.py", line 195, in setup_context
         yield
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\contextlib.py", line 131, in __exit__
         self.gen.throw(type, value, traceback)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\sandbox.py", line 166, in save_modules
         saved_exc.resume()
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\sandbox.py", line 141, in resume
         six.reraise(type, exc, self._tb)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\_vendor\six.py", line 685, in reraise
         raise value.with_traceback(tb)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\sandbox.py", line 154, in save_modules
         yield saved
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\sandbox.py", line 195, in setup_context
         yield
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\sandbox.py", line 250, in run_setup
         _execfile(setup_script, ns)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\sandbox.py", line 45, in _execfile
         exec(code, globals, locals)
       File "C:\Users\Hussam\AppData\Local\Temp\easy_install-ez_wj3mg\Cython-0.29.10\setup.py", line 228, in <module>
         This version of Cython is untested with Kivy. While this version may
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\__init__.py", line 145, in setup
         return distutils.core.setup(**attrs)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\distutils\core.py", line 163, in setup
         raise SystemExit("error: " + str(msg))
     SystemExit: error: 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\Hussam\AppData\Local\Temp\pip-install-wmjvsmt5\Kivy\setup.py", line 1073, in <module>
         setup(
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\__init__.py", line 144, in setup
         _install_setup_requires(attrs)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\__init__.py", line 139, in _install_setup_requires
         dist.fetch_build_eggs(dist.setup_requires)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\dist.py", line 716, in fetch_build_eggs
         resolved_dists = pkg_resources.working_set.resolve(
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\pkg_resources\__init__.py", line 780, in resolve
         dist = best[req.key] = env.best_match(
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\pkg_resources\__init__.py", line 1065, in best_match
         return self.obtain(req, installer)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\pkg_resources\__init__.py", line 1077, in obtain
         return installer(requirement)
       File "c:\users\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\dist.py", line 786, in fetch_build_egg
         return cmd.easy_install(req)
       File "c:\users\hussam\appdata\local\programs\python\python38\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\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\command\easy_install.py", line 705, in install_item
         dists = self.install_eggs(spec, download, tmpdir)
       File "c:\users\hussam\appdata\local\programs\python\python38\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\hussam\appdata\local\programs\python\python38\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\hussam\appdata\local\programs\python\python38\lib\site-packages\setuptools\command\easy_install.py", line 1146, in run_setup
         raise DistutilsError("Setup script exited with %s" % (v.args[0],))
     distutils.errors.DistutilsError: Setup script exited with error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": https://visualstudio.microsoft.com/downloads/
    ----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

当我使用 python 3.7.5 kivy 工作正常但新的不是
是python版本的问题吗?
任何解决方案
谢谢

最有用的评论

我们不太可能将 3.8 的 1.11.1 版本发布到 pypi。 但是,您可以使用pip install kivy[base] kivy_examples --pre --extra-index-url https://kivy.org/downloads/simple/安装 kivy master。

所有12条评论

你好。

SystemExit:错误:需要 Microsoft Visual C++ 14.0。

您可以在https://visualstudio.microsoft.com/fr/thank-you-downloading-visual-studio/?sku=BuildTools&rel=16上下载构建工具

@GwenaelPellenArkeup这是因为安装程序试图在轮子中没有预构建二进制文件的情况下进行编译。

Kivy 应该很快就会发布 3.8 轮毂。

等待https://github.com/appveyor/ci/issues/3142。

另外,似乎在 3.8 发布时 manylinux wheel 的构建被破坏了,并且自 10 月初以来 manylinux 轮子没有构建。

我认为这个错误是因为 kivy 直到新版本仍然不支持 python 3.8.0

我有同样的问题,我在想它的 macosCatalina,谢谢,这对python3.8 的新 kivy 支持何时可用,这非常有帮助?

你好
如果您转到 kivy 下载页面,您将看到支持的版本
kivy 的 python 是 2.7 和 5.3 到 3.7
所以kivy还不支持python 3.8

在星期四,2019年11月14日在下午3时49分利奥Igane [email protected]写道:

我有同样的问题,我在想它的 macosCatalina,谢谢
当新的 kivy 支持 python3.8 时,这对任何想法都非常有帮助
能得到的?


您收到此消息是因为您修改了打开/关闭状态。
直接回复本邮件,在GitHub上查看
https://github.com/kivy/kivy/issues/6563?email_source=notifications&email_token=AMTCWTX4EGQ22LWIVODYIE3QTVJP7A5CNFSM4JC3XXIKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEEB4NZA#issuecomment-553895652
或取消订阅
https://github.com/notifications/unsubscribe-auth/AMTCWTTPJ5NW7PMXGXA3EV3QTVJP7ANCNFSM4JC3XXIA
.

这是固定的吗? 我仍然不能在 python 3.8 中使用 kivy。 它显示它仅适用于 python 2.7,但是,它即将被 2.7 弃用:/请帮忙

它的 12 月现在 kivy 没有安装。 我现在应该怎么办。
有谁知道需要多长时间? 切换到旧版本的python 是唯一的选择吗?

尝试通过从https://www.lfd.uci.edu/~gohlke/pythonlibs/#kivy下载 kivy 进行安装
并且不要使用pycharm

我们不太可能将 3.8 的 1.11.1 版本发布到 pypi。 但是,您可以使用pip install kivy[base] kivy_examples --pre --extra-index-url https://kivy.org/downloads/simple/安装 kivy master。

我们不太可能将 3.8 的 1.11.1 版本发布到 pypi。 但是,您可以使用pip install kivy[base] kivy_examples --pre --extra-index-url https://kivy.org/downloads/simple/安装 kivy master。

谢谢!

我们不太可能将 3.8 的 1.11.1 版本发布到 pypi。 但是,您可以使用pip install kivy[base] kivy_examples --pre --extra-index-url https://kivy.org/downloads/simple/安装 kivy master。

谢谢一堆。 这最终真的对我有用。 但是我必须使用 pycharm 选择 Python 2.7 作为我的基本解释器。 我真的爱上了 kivy,但它并不合作。

终于意识到仍然没有更新版本的 kivy 可以与 python 3.8 一起工作。哦,来吧 kivy!

此页面是否有帮助?
0 / 5 - 0 等级