【发布时间】:2019-10-16 20:38:43
【问题描述】:
我安装了两个版本的 python。 2.7 和 3.7.4。我想将 Pygame 安装到 3.7 但失败了。
我尝试了多个教程和方法,但没有运气。 Python 2.7 包含所有文件,但 3.7 只有 exes 但仍然可以正常工作。
【问题讨论】:
标签: python python-3.x pygame
我安装了两个版本的 python。 2.7 和 3.7.4。我想将 Pygame 安装到 3.7 但失败了。
我尝试了多个教程和方法,但没有运气。 Python 2.7 包含所有文件,但 3.7 只有 exes 但仍然可以正常工作。
【问题讨论】:
标签: python python-3.x pygame
如果您使用 pip,您可以随时尝试指定要安装的确切 Python 版本:
$ python2.7 -m pip install pygame
$ python3.7 -m pip install pypgame
【讨论】:
python3.7 : The term 'python3.7' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. At line:1 char:1 + python3.7 -m pip install pygame + ~~~~~~~~~ + CategoryInfo : ObjectNotFound: (python3.7:String) [], CommandNotFoundException + FullyQualifiedErrorId : CommandNotFoundException
PS C:\Users\alexa\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Python 3.7>。需要更具体吗?
bin 目录下有python.exe。我会尝试使用它。
./python 而不仅仅是 python。谢谢!