无法在Windows 10上安装PyGTK

时间:2020-10-13 22:06:46

标签: python python-3.x cmd pip windows-10

我已经安装了Python以及PIP和PyObject v 1.0,
但是尝试安装PyGTK会引发错误。稍后将添加其他相关问题。
给定的输出错误在下面列出。我正在使用Github的Windows 10和Hyper CMD。

Microsoft Windows [Version 10.0.19041.508]
(c) 2020 Microsoft Corporation. All rights reserved.

C:\Users\Ryan>cd Desktop

C:\Users\Ryan\Desktop>cd Python

C:\Users\Ryan\Desktop\Python>pip install PyGTK
Collecting PyGTK
  Using cached pygtk-2.24.0.tar.bz2 (2.4 MB)
    ERROR: Command errored out with exit status 1:
     command: 'c:\python38\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\Ryan\\AppData\\Local\\Temp\\pip-install-dvq3hehj\\pygtk\\setup.py'"'"'; __file__='"'"'C:\\Users\\Ryan\\AppData\\Local\\Temp\\pip-install-dvq3hehj\\pygtk\\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\Ryan\AppData\Local\Temp\pip-pip-egg-info-_fc9fnz2'
         cwd: C:\Users\Ryan\AppData\Local\Temp\pip-install-dvq3hehj\pygtk\
    Complete output (1 lines):
    ERROR: Could not import dsextras module: Make sure you have installed pygobject.
    ----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

C:\Users\Ryan\Desktop\Python>pip install pyobject
Collecting pyobject
  Downloading pyobject-1.0.tar.gz (12 kB)
Using legacy 'setup.py install' for pyobject, since package 'wheel' is not installed.
Installing collected packages: pyobject
    Running setup.py install for pyobject ... done
Successfully installed pyobject-1.0

C:\Users\Ryan\Desktop\Python>pip install pygtk
Collecting pygtk
  Using cached pygtk-2.24.0.tar.bz2 (2.4 MB)
    ERROR: Command errored out with exit status 1:
     command: 'c:\python38\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\Ryan\\AppData\\Local\\Temp\\pip-install-qotfp_ry\\pygtk\\setup.py'"'"'; __file__='"'"'C:\\Users\\Ryan\\AppData\\Local\\Temp\\pip-install-qotfp_ry\\pygtk\\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\Ryan\AppData\Local\Temp\pip-pip-egg-info-p2eqklxp'
         cwd: C:\Users\Ryan\AppData\Local\Temp\pip-install-qotfp_ry\pygtk\
    Complete output (1 lines):
    ERROR: Could not import dsextras module: Make sure you have installed pygobject.
    ----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

C:\Users\Ryan\Desktop\Python>

可能相关的问题:: >>
Pip install unroll Python Setup PyEgg
Pip Install PyGTK Error
ReadTheDocs => PygObject

如果PyGTK是python软件包,那么为什么要依赖于MSYS2之类的程序来安装,而如果确实需要安装,为什么终端不将其提及为错误或必要的依赖关系呢?

ReadTheDocs网站上给定的示例图片看起来就像是将它们安装在1970年代的Windows系统上一样,因此不确定该文章的最新程度。说Windows 7及更高版本。我正在运行Windows 10 Home,最新更新...

Ps PyGTK有哪些好的替代品?
有什么更好的GUI PyGTK alternatives
不确定要查看列表中的哪些人有没有使用过其中的任何一个?

已被重复提出的问题已存在3年以上,并且MSYS2仍然看起来不是最新的或未得到积极维护。另外,我使用的是其他版本的python。

寻找一种在Windows上构建GUI的简单方法,用于基本任务和学习。

0 个答案:

没有答案