命令出错,退出状态为1:python setup.py egg_info通过pip安装turtle时,请查看日志以获取完



我正试图通过pip在我通常使用的(Linux(设备上下载turtle。然而,当运行时,我得到了错误(对不起,它太长了(:

ERROR: Command errored out with exit status 1:
command: /usr/bin/python3 -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-qx1dkmxw/turtle/setup.py'"'"'; __file__='"'"'/tmp/pip-install-qx1dkmxw/turtle/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'rn'"'"', '"'"'n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-install-qx1dkmxw/turtle/pip-egg-info
cwd: /tmp/pip-install-qx1dkmxw/turtle/
Complete output (6 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-qx1dkmxw/turtle/setup.py", line 40
except ValueError, ve:
^
SyntaxError: invalid syntax
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

https://pypi.org/project/turtle/0.0.2版本,最新发布于2009年。该代码显然适用于Python 2。

建议:试试Python 2.7。或者忘记包裹。

向上。标准库中有模块turtle。这可能是你想要的。您不需要安装它,它应该已经和stdlib一起存在了。

最新更新