简体   繁体   English

无法使用 Python 3.10.0 安装 kivy

[英]Can't install kivy with Python 3.10.0

I'm new to python.我是 python 的新手。 I'm getting an error when installing kivy with pip install kivy安装kivypip 安装 kivy时出现错误

C:\Users\Acer>pip install kivy
Collecting kivy
  Using cached Kivy-2.0.0.tar.gz (23.7 MB)
  Installing build dependencies ... error
  ERROR: Command errored out with exit status 1:
   command: 'C:\Users\Acer\AppData\Local\Programs\Python\Python310\python.exe' 'C:\Users\Acer\AppData\Local\Temp\pip-standalone-pip-wd83fnja\__env_pip__.zip\pip' install --ignore-installed --no-user --prefix 'C:\Users\Acer\AppData\Local\Temp\pip-build-env-gfj6fhoh\overlay' --no-warn-script-location --no-binary :none: --only-binary :none: -i https://pypi.org/simple -- setuptools wheel 'cython>=0.24,<=0.29.21,!=0.27,!=0.27.2' 'kivy_deps.gstreamer_dev~=0.3.1; sys_platform == "win32"' 'kivy_deps.sdl2_dev~=0.3.1; sys_platform == "win32"' 'kivy_deps.glew_dev~=0.3.0; sys_platform == "win32"' 'kivy_deps.gstreamer~=0.3.1; sys_platform == "win32"' 'kivy_deps.sdl2~=0.3.1; sys_platform == "win32"' 'kivy_deps.glew~=0.3.0; sys_platform == "win32"'
       cwd: None
  Complete output (10 lines):
  Collecting setuptools
    Using cached setuptools-59.2.0-py3-none-any.whl (952 kB)
  Collecting wheel
    Using cached wheel-0.37.0-py2.py3-none-any.whl (35 kB)
  Collecting cython!=0.27,!=0.27.2,<=0.29.21,>=0.24
    Using cached Cython-0.29.21-py2.py3-none-any.whl (974 kB)
  Collecting kivy_deps.gstreamer_dev~=0.3.1
    Using cached kivy_deps.gstreamer_dev-0.3.2-cp310-cp310-win_amd64.whl (3.9 MB)
  ERROR: Could not find a version that satisfies the requirement kivy_deps.sdl2_dev~=0.3.1 (from versions: 0.4.2, 0.4.3)
  ERROR: No matching distribution found for kivy_deps.sdl2_dev~=0.3.1
  ----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/12/96/091ddacafb84dd18555a32d860dbfaf9c806147aa30c6f3c8b93cb7bab97/Kivy-2.0.0.tar.gz#sha256=d25e44eb44e43762b2fd0c5874e51954e0f1181fd9800d8a6756be6d084812d8 (from https://pypi.org/simple/kivy/). Command errored out with exit status 1: 'C:\Users\Acer\AppData\Local\Programs\Python\Python310\python.exe' 'C:\Users\Acer\AppData\Local\Temp\pip-standalone-pip-wd83fnja\__env_pip__.zip\pip' install --ignore-installed --no-user --prefix 'C:\Users\Acer\AppData\Local\Temp\pip-build-env-gfj6fhoh\overlay' --no-warn-script-location --no-binary :none: --only-binary :none: -i https://pypi.org/simple -- setuptools wheel 'cython>=0.24,<=0.29.21,!=0.27,!=0.27.2' 'kivy_deps.gstreamer_dev~=0.3.1; sys_platform == "win32"' 'kivy_deps.sdl2_dev~=0.3.1; sys_platform == "win32"' 'kivy_deps.glew_dev~=0.3.0; sys_platform == "win32"' 'kivy_deps.gstreamer~=0.3.1; sys_platform == "win32"' 'kivy_deps.sdl2~=0.3.1; sys_platform == "win32"' 'kivy_deps.glew~=0.3.0; sys_platform == "win32"' Check the logs for full command output.
  Using cached Kivy-1.11.1.tar.gz (23.6 MB)
  Preparing metadata (setup.py) ... error
  ERROR: Command errored out with exit status 1:

Help please请帮忙

https://github.com/kivy/kivy/releases/tag/2.0.0 https://github.com/kivy/kivy/releases/tag/2.0.0

Currently supported Python versions are 3.6 - 3.9.目前支持的 Python 版本为 3.6 - 3.9。

To sum it up, you will have to wait for a while for the developers of the Kivy project to package the library to 3.10.综上所述,Kivy项目的开发者要等package库到3.10。 Meanwhile, you can still use Kivy on Python 3.9 without any issue同时,您仍然可以在 Python 3.9 上使用 Kivy 没有任何问题

Had exactly the same problem.有完全相同的问题。 Infinite loop of downloads and dependencies errors, as it can't work with Python version 3.10 yet.无限循环的下载和依赖错误,因为它还不能与 Python 版本 3.10 一起使用。

Download one of the older Python 3.9 versions for this project (as multiple interpreter versions can coexist on the same machine) if you can't wait for the update.如果您等不及更新,请为此项目下载一个较旧的 Python 3.9 版本(因为多个解释器版本可以在同一台机器上共存)。

If you use PyCharm, you can create new project in venv, selecting 3.9 version of the interpreter and in the terminal run:如果您使用 PyCharm,您可以在 venv 中创建新项目,选择 3.9 版本的解释器并在终端中运行:

python -m pip install kivy[base] kivy_examples

(FIX) Я решил эту проблему так! (修复)Я решил эту проблему так! I solved this problem like!我解决了这个问题! https://zen.yandex.ru/media/id/5d5121db35ca3100ad73ffba/kak-zapustit-kyvi-v-python310-fix-kostyl-61f52827c06bbe1c28c39284 https://zen.yandex.ru/media/id/5d5121db35ca3100ad73ffba/kak-zapustit-kyvi-v-python310-fix-kostyl-61f52827c06bbe1c28c39284

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM