为什么我不能安装paho

时间:2020-06-29 11:25:40

标签: python pip ironpython paho

我正在用Ironpython编程,想使用Paho。

我做了以下事情:

C:\Program Files\IronPython 2.7\Scripts>pip install paho-mqtt
Collecting paho-mqtt
 Using cached https://files.pythonhosted.org/packages/59/11/1dd5c70f0f27a88a3a05772cd95f6087ac479fac66d9c7752ee5e16ddbbc/paho-mqtt-1.5.0.tar.gz

  Complete output from command python setup.py egg_info:
  Traceback (most recent call last):
   File "<string>", line 1, in <module>
   File "c:\program files\ironpython 2.7\Lib\site-packages\setuptools\__init__.py", line 151, in <module>
  TypeError: a new-style class can't have only classic bases

  ----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in c:\users\appdata\local\temp\pip-install-8fzpf3\paho-mqtt\
You are using pip version 18.1, however version 20.2b1 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.

对此错误进行了Google搜索,并导致以下错误(({Python: setup.py egg_info failed with error code 1):

确保它是最新的

pip install --upgrade setuptools 确保模块ez_setup不丢失

pip install ez_setup 然后试试这个

pip安装展开 如果仍然无法正常工作,请尝试

easy_install -U setuptools 然后

pip安装展开

但是,pip install ez_setup命令返回相同的错误:

C:\Program Files\IronPython 2.7\Scripts>pip install ez_setup
Collecting ez_setup
 Using cached https://files.pythonhosted.org/packages/ba/2c/743df41bd6b3298706dfe91b0c7ecdc47f2dc1a3104abeb6e9aa4a45fa5d/ez_setup-0.9.tar.gz

  Complete output from command python setup.py egg_info:
  Traceback (most recent call last):
   File "<string>", line 1, in <module>
   File "c:\program files\ironpython 2.7\Lib\site-packages\setuptools\__init__.py", line 170, in <module>
  TypeError: a new-style class can't have only classic bases



  ----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in c:\users\albin\appdata\local\temp\pip-install-myrxp0\ez-setup\
You are using pip version 18.1, however version 20.2b1 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.

0 个答案:

没有答案