【发布时间】:2021-03-16 00:47:52
【问题描述】:
尝试在 Mac 上的 python 2.7 上使用 pip 安装 terraform_utils。
ERROR: Command errored out with exit status 1:
command: /System/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/tmp/pip-install-p0O4_9/terraform-utils/setup.py'"'"'; __file__='"'"'/private/tmp/pip-install-p0O4_9/terraform-utils/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 /private/tmp/pip-pip-egg-info-30t_an
cwd: /private/tmp/pip-install-p0O4_9/terraform-utils/
Complete output (6 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/private/tmp/pip-install-p0O4_9/terraform-utils/setup.py", line 8
def read_file(path: Union[str, Path]) -> str:
^
SyntaxError: invalid syntax
----------------------------------------
错误:命令出错,退出状态为 1:python setup.py egg_info 检查日志以获取完整的命令输出。
任何人都可以帮助解决上述错误吗?无法弄清楚缺少什么!
【问题讨论】:
标签: python macos python-2.7 terraform