[当我尝试使用pip3 install pyttsx3
安装pyttsx3时,收到以下输出:
Defaulting to user installation because normal site-packages is not writeable
Collecting pyttsx3
Using cached pyttsx3-2.84-py3-none-any.whl (39 kB)
Collecting pyobjc>=2.4
Using cached pyobjc-6.1-py3-none-any.whl (2.9 kB)
Collecting pyobjc-framework-WebKit==6.1
Using cached pyobjc-framework-WebKit-6.1.tar.gz (444 kB)
ERROR: Command errored out with exit status 1:
command: /usr/bin/python3 -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-j0j43b8e/pyobjc-framework-WebKit/setup.py'"'"'; __file__='"'"'/tmp/pip-install-j0j43b8e/pyobjc-framework-WebKit/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-j0j43b8e/pyobjc-framework-WebKit/pip-egg-info
cwd: /tmp/pip-install-j0j43b8e/pyobjc-framework-WebKit/
Complete output (15 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-j0j43b8e/pyobjc-framework-WebKit/setup.py", line 27, in <module>
for fn in os.listdir("Modules")
File "/tmp/pip-install-j0j43b8e/pyobjc-framework-WebKit/pyobjc_setup.py", line 408, in Extension
os_level = get_os_level()
File "/tmp/pip-install-j0j43b8e/pyobjc-framework-WebKit/pyobjc_setup.py", line 218, in get_os_level
pl = plistlib.readPlist("/System/Library/CoreServices/SystemVersion.plist")
File "/usr/lib/python3.7/plistlib.py", line 99, in readPlist
with _maybe_open(pathOrFile, 'rb') as fp:
File "/usr/lib/python3.7/contextlib.py", line 112, in __enter__
return next(self.gen)
File "/usr/lib/python3.7/plistlib.py", line 82, in _maybe_open
with open(pathOrFile, mode) as fp:
FileNotFoundError: [Errno 2] No such file or directory: '/System/Library/CoreServices/SystemVersion.plist'
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
我正在使用Python 3.7.5,pip版本20.0.2,Ubuntu 19.10。
我已经尝试升级设置工具。
似乎已经问过相同的问题here,但答案是模棱两可和不完整的。