[英]How to fix error “ERROR: Command errored out with exit status 1: python.” when trying to install pyttsx3 using pip
[英]How to fix error “ERROR: Command errored out with exit status 1: python.” when trying to install djangorestframework-extensions using pip
我正在嘗試使用以下命令安裝 djangorestframework-extensions:
pip install djangorestframework-extensions
它顯示了錯誤:
ERROR: Command errored out with exit status 1:
command: /home/anamaria/workspace/licenta/AllFest2/festivals/venv/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-r9q6vdlo/djangorestframework-extensions/setup.py'"'"'; __file__='"'"'/tmp/pip-install-r9q6vdlo/djangorestframework-extensions/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 /tmp/pip-install-r9q6vdlo/djangorestframework-extensions/pip-egg-info
cwd: /tmp/pip-install-r9q6vdlo/djangorestframework-extensions/
Complete output (6 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-r9q6vdlo/djangorestframework-extensions/setup.py", line 48
print "You probably want to also tag the version now:"
^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print("You probably want to also tag the version now:")?
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
我該怎么辦?
這個包似乎在 Python2 和 python3 之間不兼容。 您可以嘗試手動修復“/tmp/pip-install-r9q6vdlo/djangorestframework-extensions/setup.py”,將所有 '''print something''' 替換為 '''print(something)''' 它可能會失敗,所以如果您有選擇,盡管 python 2 現在已經很舊,但使用 python 2 運行它可能會更好。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.