Collecting turtle Using cached https://files.pythonhosted.org/packages/ff/f0/21a42e9e424d24bdd0e509d5ed3c7dfb8f47d962d9c044dba903b0b4a26f/turtle-0.0.2.tar.gz ERROR: Complete output from command python setup.py egg_info: ERROR: Traceback (most recent call last): File "<string>", line 1, in <module> File "/private/var/folders/1b/zd3_1j0d5cn5pz5cd20098ph0000gn/T/pip-install-ckvgi1nr/turtle/setup.py", line 40 except ValueError, ve: ^ SyntaxError: invalid syntax ---------------------------------------- ERROR: Command "python setup.py egg_info" failed with error code 1 in /private/var/folders/1b/zd3_1j0d5cn5pz5cd20098ph0000gn/T/pip-install-ckvgi1nr/turtle/
研究一下turtle的用法,我用的是python3.6 安装了一下,遇到了这个报错,现在记录一下解决办法:
https://pypi.org/project/turtle/#files
下载源包,手动解压,修改setup.py文件再安装。
cd turtle-0.0.2/ls vim setup.py
找到图示位置,修改
except (ValueError, ve):
退出,保存
cd .. pip install -e turtle-0.0.2
安装成功
来源:https://www.cnblogs.com/liangliangzz/p/11198021.html