繁体   English   中英

在 macOS Catalina 中使用 pip 安装 airflow 时出错

[英]Getting Errors while installing airflow using pip install apache-airflow in macOS Catalina

我在这个周末将我的学习轮转向 airflow,同时使用 pip 在本地机器上设置和安装 airflow 出现以下错误:

(base) ItGuy-MacBook-Pro:~ gofrogs$ pip install apache-airflow






  Stored in directory: /Users/gofrogs/Library/Caches/pip/wheels/41/d4/fa/31df9cc56ee41572a4dfc1be7dfc87df59a5d6a7fd03e97eab
  Building wheel for setproctitle (setup.py) ... error
  ERROR: Command errored out with exit status 1:
   command: /Users/gofrogs/Downloads/anaconda3/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/7s/9jm62xrs77x3mvsjfkd_7fq80000gn/T/pip-install-hnedol5a/setproctitle/setup.py'"'"'; __file__='"'"'/private/var/folders/7s/9jm62xrs77x3mvsjfkd_7fq80000gn/T/pip-install-hnedol5a/setproctitle/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /private/var/folders/7s/9jm62xrs77x3mvsjfkd_7fq80000gn/T/pip-wheel-78zrb1fy
       cwd: /private/var/folders/7s/9jm62xrs77x3mvsjfkd_7fq80000gn/T/pip-install-hnedol5a/setproctitle/
  Complete output (10 lines):
  running bdist_wheel
  running build
  running build_ext
  building 'setproctitle' extension
  creating build
  creating build/temp.macosx-10.9-x86_64-3.7
  creating build/temp.macosx-10.9-x86_64-3.7/src
  gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/Users/gofrogs/Downloads/anaconda3/include -arch x86_64 -I/Users/gofrogs/Downloads/anaconda3/include -arch x86_64 -DSPT_VERSION=1.1.10 -D__darwin__=1 -I/Users/gofrogs/Downloads/anaconda3/include/python3.7m -c src/setproctitle.c -o build/temp.macosx-10.9-x86_64-3.7/src/setproctitle.o
  xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
  error: command 'gcc' failed with exit status 1
  ----------------------------------------
  ERROR: Failed building wheel for setproctitle

Successfully built thrift flask-admin termcolor alembic dill pendulum flask-login flask-swagger json-merge-patch tzlocal Flask-JWT-Extended sqlalchemy-utils Flask-OpenID
Failed to build setproctitle
Installing collected packages: thrift, flask-caching, cached-property, wtforms, flask-admin, lockfile, python-daemon, tabulate, configparser, markdown, sqlalchemy-jsonfield, text-unidecode, termcolor, python-editor, Mako, alembic, dill, attrs, pytzdata, tzlocal, pendulum, argcomplete, setproctitle, PyJWT, Flask-JWT-Extended, marshmallow, flask-wtf, Flask-Babel, marshmallow-enum, Flask-SQLAlchemy, prison, flask-login, sqlalchemy-utils, apispec, marshmallow-sqlalchemy, python3-openid, Flask-OpenID, flask-appbuilder, cattrs, colorlog, graphviz, typing-extensions, croniter, flask-swagger, iso8601, tenacity, funcsigs, json-merge-patch, zope.deprecation, gunicorn, apache-airflow
  Attempting uninstall: attrs
    Found existing installation: attrs 19.2.0
    Uninstalling attrs-19.2.0:
      Successfully uninstalled attrs-19.2.0
    Running setup.py install for setproctitle ... error
    ERROR: Command errored out with exit status 1:
     command: /Users/gofrogs/Downloads/anaconda3/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/7s/9jm62xrs77x3mvsjfkd_7fq80000gn/T/pip-install-hnedol5a/setproctitle/setup.py'"'"'; __file__='"'"'/private/var/folders/7s/9jm62xrs77x3mvsjfkd_7fq80000gn/T/pip-install-hnedol5a/setproctitle/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /private/var/folders/7s/9jm62xrs77x3mvsjfkd_7fq80000gn/T/pip-record-cl1apnxt/install-record.txt --single-version-externally-managed --compile --install-headers /Users/gofrogs/Downloads/anaconda3/include/python3.7m/setproctitle
         cwd: /private/var/folders/7s/9jm62xrs77x3mvsjfkd_7fq80000gn/T/pip-install-hnedol5a/setproctitle/
    Complete output (10 lines):
    running install
    running build
    running build_ext
    building 'setproctitle' extension
    creating build
    creating build/temp.macosx-10.9-x86_64-3.7
    creating build/temp.macosx-10.9-x86_64-3.7/src
    gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/Users/gofrogs/Downloads/anaconda3/include -arch x86_64 -I/Users/gofrogs/Downloads/anaconda3/include -arch x86_64 -DSPT_VERSION=1.1.10 -D__darwin__=1 -I/Users/gofrogs/Downloads/anaconda3/include/python3.7m -c src/setproctitle.c -o build/temp.macosx-10.9-x86_64-3.7/src/setproctitle.o
    xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
    error: command 'gcc' failed with exit status 1
    ----------------------------------------
ERROR: Command errored out with exit status 1: /Users/gofrogs/Downloads/anaconda3/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/7s/9jm62xrs77x3mvsjfkd_7fq80000gn/T/pip-install-hnedol5a/setproctitle/setup.py'"'"'; __file__='"'"'/private/var/folders/7s/9jm62xrs77x3mvsjfkd_7fq80000gn/T/pip-install-hnedol5a/setproctitle/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /private/var/folders/7s/9jm62xrs77x3mvsjfkd_7fq80000gn/T/pip-record-cl1apnxt/install-record.txt --single-version-externally-managed --compile --install-headers /Users/gofrogs/Downloads/anaconda3/include/python3.7m/setproctitle Check the logs for full command output.

你能建议我需要修复什么吗? 此外,如果可能,请分享有关 airflow 的详细解释/教程的链接,以便我/未来的读者可以关注最好的资源?

您的问题通常与 Xcode 工具包有关。

在终端中输入此命令

xcode-select --install

如果这不起作用,您总是可以先尝试更新工具包。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM