您好,当我尝试运行时,我目前以PyObjC-core作为我的requirements.txt文件中的依赖项之一
pip install -r requirements.txt
它返回以下错误:
Collecting pyobjc-core==6.1
Using cached https://files.pythonhosted.org/packages/3a/80/0cdb2130b86a984e4765beb93135aa9c2120fd64be1a27e1c7cb31c719bc/pyobjc-core-6.1.tar.gz
ERROR: Command errored out with exit status 1:
command: /usr/local/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-vj52r5i1/pyobjc-core/setup.py'"'"'; __file__='"'"'/tmp/pip-install-vj52r5i1/pyobjc-core/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-vj52r5i1/pyobjc-core/pip-egg-info
cwd: /tmp/pip-install-vj52r5i1/pyobjc-core/
Complete output (2 lines):
running egg_info
error: PyObjC requires macOS to build
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
我在网上寻找解决方案,但仍未找到任何答案。
我的点子版本是20.0.2,并且在python 3.7上运行
我也尝试过手动安装pip install pyobjc-core
,但还是没有运气
[如此处https://github.com/asweigart/pyautogui/issues/381所述,我相信当前唯一的解决方案是安装pyautogui的旧版本:https://pypi.org/project/PyAutoGUI/0.9.50/#history。