无法安装一些带有无效组名错误的pip软件包

问题描述

我正在使用OctoPi 0.17.0Octoprint 1.4.2Python 2.7.16pip 20.2.2一起运行setuptools 44.1.1

我无法使用浏览器或或命令行安装任何插件。错误始终是相同的,如下所示。

它也直接来自pip注册表中的其他软件包(例如unicornhat),但我能够从同一pip实例成功更新pipsetuptools

~/oprint/bin/python2 -m pip --verbose install "https://github.com/gdombiak/OctoPrint-OctoPod/archive/master.zip"
DEPRECATION: Python 2.7 reached the end of its life on January 1st,2020. Please upgrade your Python as Python 2.7 is no longer maintained. pip 21.0 will drop support for Python 2.7 in January 2021. More details about Python 2 support in pip can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
Using pip 20.2.2 from /home/pi/oprint/local/lib/python2.7/site-packages/pip (python 2.7)
Non-user install because user site-packages disabled
Created temporary directory: /tmp/pip-ephem-wheel-cache-b8DVyx
Created temporary directory: /tmp/pip-req-tracker-xiZrDj
Initialized build tracking at /tmp/pip-req-tracker-xiZrDj
Created build tracker: /tmp/pip-req-tracker-xiZrDj
Entered build tracker: /tmp/pip-req-tracker-xiZrDj
Created temporary directory: /tmp/pip-install-B6fEYT
Looking in indexes: https://pypi.org/simple,https://www.piwheels.org/simple
Collecting https://github.com/gdombiak/OctoPrint-OctoPod/archive/master.zip
  Created temporary directory: /tmp/pip-req-build-Fcmtzn
  Created temporary directory: /tmp/pip-unpack-F09Hys
  Looking up "https://github.com/gdombiak/OctoPrint-OctoPod/archive/master.zip" in the cache
  No cache entry available
  Starting new HTTPS connection (1): github.com:443
  https://github.com:443 "GET /gdombiak/OctoPrint-OctoPod/archive/master.zip HTTP/1.1" 302 None
  Status code 302 not in (200,203,300,301)
  Looking up "https://codeload.github.com/gdombiak/OctoPrint-OctoPod/zip/master" in the cache
  Current age based on date: 1704
  Starting new HTTPS connection (1): codeload.github.com:443
  https://codeload.github.com:443 "GET /gdombiak/OctoPrint-OctoPod/zip/master HTTP/1.1" 304 0
  Using cached https://github.com/gdombiak/OctoPrint-OctoPod/archive/master.zip
  Added https://github.com/gdombiak/OctoPrint-OctoPod/archive/master.zip to build tracker '/tmp/pip-req-tracker-xiZrDj'
    Running setup.py (path:/tmp/pip-req-build-Fcmtzn/setup.py) egg_info for package from https://github.com/gdombiak/OctoPrint-OctoPod/archive/master.zip
    Created temporary directory: /tmp/pip-pip-egg-info-DcgyUj
    Running command python setup.py egg_info
    Found packages: set(['octoprint_octopod'])
    Traceback (most recent call last):
      File "<string>",line 1,in <module>
      File "/tmp/pip-req-build-Fcmtzn/setup.py",line 96,in <module>
        setup(**setup_parameters)
      File "/home/pi/oprint/local/lib/python2.7/site-packages/setuptools/__init__.py",line 161,in setup
        _install_setup_requires(attrs)
      File "/home/pi/oprint/local/lib/python2.7/site-packages/setuptools/__init__.py",line 151,in _install_setup_requires
        dist = MinimalDistribution(attrs)
      File "/home/pi/oprint/local/lib/python2.7/site-packages/setuptools/__init__.py",line 143,in __init__
        distutils.core.Distribution.__init__(self,filtered)
      File "/home/pi/oprint/local/lib/python2.7/site-packages/setuptools/dist.py",line 445,in __init__
        for ep in pkg_resources.iter_entry_points('distutils.setup_keywords'):
      File "/home/pi/oprint/local/lib/python2.7/site-packages/pkg_resources/__init__.py",line 656,in <genexpr>
        for entry in dist.get_entry_map(group).values()
      File "/home/pi/oprint/local/lib/python2.7/site-packages/pkg_resources/__init__.py",line 2860,in get_entry_map
        self._get_metadata('entry_points.txt'),self
      File "/home/pi/oprint/local/lib/python2.7/site-packages/pkg_resources/__init__.py",line 2535,in parse_map
        maps[group] = cls.parse_group(group,lines,dist)
      File "/home/pi/oprint/local/lib/python2.7/site-packages/pkg_resources/__init__.py",line 2510,in parse_group
        raise ValueError("Invalid group name",group)
    ValueError: ('Invalid group name','console\xdescripts')
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Exception information:
Traceback (most recent call last):
  File "/home/pi/oprint/local/lib/python2.7/site-packages/pip/_internal/cli/base_command.py",line 216,in _main
    status = self.run(options,args)
  File "/home/pi/oprint/local/lib/python2.7/site-packages/pip/_internal/cli/req_command.py",line 182,in wrapper
    return func(self,options,args)
  File "/home/pi/oprint/local/lib/python2.7/site-packages/pip/_internal/commands/install.py",line 325,in run
    reqs,check_supported_wheels=not options.target_dir
  File "/home/pi/oprint/local/lib/python2.7/site-packages/pip/_internal/resolution/legacy/resolver.py",line 183,in resolve
    discovered_reqs.extend(self._resolve_one(requirement_set,req))
  File "/home/pi/oprint/local/lib/python2.7/site-packages/pip/_internal/resolution/legacy/resolver.py",line 388,in _resolve_one
    abstract_dist = self._get_abstract_dist_for(req_to_install)
  File "/home/pi/oprint/local/lib/python2.7/site-packages/pip/_internal/resolution/legacy/resolver.py",line 340,in _get_abstract_dist_for
    abstract_dist = self.preparer.prepare_linked_requirement(req)
  File "/home/pi/oprint/local/lib/python2.7/site-packages/pip/_internal/operations/prepare.py",line 483,in prepare_linked_requirement
    req,self.req_tracker,self.finder,self.build_isolation,File "/home/pi/oprint/local/lib/python2.7/site-packages/pip/_internal/operations/prepare.py",line 91,in _get_prepared_distribution
    abstract_dist.prepare_distribution_metadata(finder,build_isolation)
  File "/home/pi/oprint/local/lib/python2.7/site-packages/pip/_internal/distributions/sdist.py",line 40,in prepare_distribution_metadata
    self.req.prepare_metadata()
  File "/home/pi/oprint/local/lib/python2.7/site-packages/pip/_internal/req/req_install.py",line 554,in prepare_metadata
    self.metadata_directory = self._generate_metadata()
  File "/home/pi/oprint/local/lib/python2.7/site-packages/pip/_internal/req/req_install.py",line 534,in _generate_metadata
    details=self.name or "from {}".format(self.link)
  File "/home/pi/oprint/local/lib/python2.7/site-packages/pip/_internal/operations/build/metadata_legacy.py",line 73,in generate_metadata
    command_desc='python setup.py egg_info',File "/home/pi/oprint/local/lib/python2.7/site-packages/pip/_internal/utils/subprocess.py",line 242,in call_subprocess
    raise InstallationError(exc_msg)
InstallationError: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Removed https://github.com/gdombiak/OctoPrint-OctoPod/archive/master.zip from build tracker '/tmp/pip-req-tracker-xiZrDj'
Removed build tracker: '/tmp/pip-req-tracker-xiZrDj'

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)

相关问答

错误1:Request method ‘DELETE‘ not supported 错误还原:...
错误1:启动docker镜像时报错:Error response from daemon:...
错误1:private field ‘xxx‘ is never assigned 按Alt...
报错如下,通过源不能下载,最后警告pip需升级版本 Requirem...