本文介绍了“pip install -U 频道"错误用于 otree 的命令(运行 setup.py bdist_wheel 用于扭曲...错误)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

对于使用 otree (http://otree.readthedocs.io/) 的项目,我遇到了尝试安装 Channels 以使用实时功能时遇到的一些问题.

For a project using otree (http://otree.readthedocs.io/) I ran into some problems trying to install Channels in order to make use of real-time functionalities.

由于输出很长,我试图找出最重要的部分:

Because of the long output I tried to figure out the most important parts:

有关完整输出,请参阅:https://jsfiddle.net/L4ccmr2k/1/

For full output see: https://jsfiddle.net/L4ccmr2k/1/

红色标记的输出&我认为相关的输出:

1.

 Building wheels for collected packages: twisted
      Running setup.py bdist_wheel for twisted ... error

2.

creating build/temp.macosx-10.6-intel-3.6
      creating build/temp.macosx-10.6-intel-3.6/src
      creating build/temp.macosx-10.6-intel-3.6/src/twisted
      creating build/temp.macosx-10.6-intel-3.6/src/twisted/test
      /usr/bin/clang -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -arch i386 -arch x86_64 -g -I/Library/Frameworks/Python.framework/Versions/3.6/include/python3.6m -c src/twisted/test/raiser.c -o build/temp.macosx-10.6-intel-3.6/src/twisted/test/raiser.o
      xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
      error: command '/usr/bin/clang' failed with exit status 1

      ----------------------------------------
      Failed building wheel for twisted
      Running setup.py clean for twisted
    Failed to build twisted
    Installing collected packages: twisted, daphne, channels
      Running setup.py install for twisted ... error
        Complete output from command /Library/Frameworks/Python.framework/Versions/3.6/bin/python3.6 -u -c "import setuptools, tokenize;__file__='/private/var/folders/6_/30pgp_bj17j3krgq_kt0py440000gn/T/pip-build-v4kcayoj/twisted/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('
', '
');f.close();exec(compile(code, __file__, 'exec'))" install --record /var/folders/6_/30pgp_bj17j3krgq_kt0py440000gn/T/pip-vpnlc5lo-record/install-record.txt --single-version-externally-managed --compile:

3.

creating build/temp.macosx-10.6-intel-3.6
    creating build/temp.macosx-10.6-intel-3.6/src
    creating build/temp.macosx-10.6-intel-3.6/src/twisted
    creating build/temp.macosx-10.6-intel-3.6/src/twisted/test
    /usr/bin/clang -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -arch i386 -arch x86_64 -g -I/Library/Frameworks/Python.framework/Versions/3.6/include/python3.6m -c src/twisted/test/raiser.c -o build/temp.macosx-10.6-intel-3.6/src/twisted/test/raiser.o
    xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
    error: command '/usr/bin/clang' failed with exit status 1

    ----------------------------------------
Command "/Library/Frameworks/Python.framework/Versions/3.6/bin/python3.6 -u -c "import setuptools, tokenize;__file__='/private/var/folders/6_/30pgp_bj17j3krgq_kt0py440000gn/T/pip-build-v4kcayoj/twisted/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('
', '
');f.close();exec(compile(code, __file__, 'exec'))" install --record /var/folders/6_/30pgp_bj17j3krgq_kt0py440000gn/T/pip-vpnlc5lo-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/var/folders/6_/30pgp_bj17j3krgq_kt0py440000gn/T/pip-build-v4kcayoj/twisted/

我正在使用:

  • macOS 10.12.6
  • Python 2.7.10
  • wheel-0.30.0
  • 来自/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (python 3.6) 的 pip 9.0.1
  • Django-1.8.8
  • Twisted-16.2.0
  • asgiref-0.14.0
  • 高速公路-0.16.0
  • channels-0.17.3
  • otree-core-1.4.28
  • pytz-2016.6.1
  • 6-1.10.0
  • txaio-2.5.1
  • wheel-0.29.0
  • zope.interface-4.2.0

推荐答案

尝试运行这些命令

xcode-select --installxcode-select --switch/Applications/Xcode.appxcode-select --switch/Library/Developer/CommandLineTools

只是为了确保正确应用您的设置

just to make sure your setup is properly applied

这篇关于“pip install -U 频道"错误用于 otree 的命令(运行 setup.py bdist_wheel 用于扭曲...错误)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

05-16 23:28