问题描述
我正在尝试使用
将 Nagios LogServer 安装到原始 CentOS 7.2.1511 上curl https://assets.nagios.com/downloads/nagios-log-server/install.sh | sh
我收到这个初始错误
Downloading https://files.pythonhosted.org/packages/21/83/308a74ca1104fe1e3197d31693a7a2db67c2d4e668f20f43a2fca491f9f7/click-8.0.1.tar.gz (327kB)
Complete output from command python setup.py egg_info:
error in click setup command: 'install_requires' must be a string or list of strings containing valid project/version requirement specifiers
----------------------------------------
Command "python setup.py egg_info" Failed with error code 1 in /tmp/pip-build-fy2L78/click/
You are using pip version 8.1.2,however version 21.1.3 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
然后运行
pip install --upgrade pip
并重新运行安装,得到
Traceback (most recent call last):
File "/usr/bin/pip",line 9,in <module>
load_entry_point('pip==21.1.3','console_scripts','pip')()
File "/usr/lib/python2.7/site-packages/pkg_resources.py",line 378,in load_entry_point
return get_distribution(dist).load_entry_point(group,name)
File "/usr/lib/python2.7/site-packages/pkg_resources.py",line 2566,in load_entry_point
return ep.load()
File "/usr/lib/python2.7/site-packages/pkg_resources.py",line 2260,in load
entry = __import__(self.module_name,globals(),['__name__'])
File "/usr/lib/python2.7/site-packages/pip/__init__.py",line 1,in <module>
from typing import List,Optional
ImportError: No module named typing
我尝试了多种解决方案,例如重新模板化服务器、安装 python 2.7、运行 pip install typing
然后运行安装。这导致
Complete output from command python setup.py egg_info:
error in click setup command: 'install_requires' must be a string or list of strings containing valid project/version requirement specifiers
Traceback (most recent call last):
File "/usr/bin/pip",['__name__'])
File "/usr/lib/python2.7/site-packages/pip/_internal/cli/main.py",line 58
sys.stderr.write(f"ERROR: {exc}")
^
SyntaxError: invalid Syntax
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)