小诚complier 2020-06-01 23:12 采纳率: 0%
浏览 479

linux与python相关的错误!!!!!

[root@iZ8vbi9ldypntZ api]# pip install -r requirements.txt
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
Looking in indexes: https://mirrors.aliyun.com/pypi/simple
Requirement already satisfied: requests in /usr/lib/python2.7/site-packages (from -r requirements.txt (line 1)) (2.23.0)
Collecting lxml
Using cached https://mirrors.aliyun.com/pypi/packages/7a/ac/e5caaa241de06024766872714c38d14e5f885dc453a4b8f9e6463b67c164/lxml-4.5.1-cp27-cp27mu-manylinux1_x86_64.whl (5.5 MB)
Collecting BeautifulSoup4
Using cached https://mirrors.aliyun.com/pypi/packages/c2/39/1efce3dc73e657c43f436533d49be1491bf8fc830caa70188d73bfd03b8d/beautifulsoup4-4.9.1-py2-none-any.whl (111 kB)
Collecting uvicorn
Using cached https://mirrors.aliyun.com/pypi/packages/9a/dd/8be4cdd599dafb69c1a2a2427eec14b218d9fc047cb0fd41060afc2852a8/uvicorn-0.11.5.tar.gz (29 kB)
ERROR: Command errored out with exit status 1:
command: /usr/bin/python2 -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-hSyTdu/uvicorn/setup.py'"'"'; file='"'"'/tmp/pip-install-hSyTdu/uvicorn/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-f96xgj
cwd: /tmp/pip-install-hSyTdu/uvicorn/
Complete output (7 lines):
Traceback (most recent call last):
File "", line 1, in
File "/tmp/pip-install-hSyTdu/uvicorn/setup.py", line 56, in
version=get_version("uvicorn"),
File "/tmp/pip-install-hSyTdu/uvicorn/setup.py", line 15, in get_version
init_py = open(path, "r", encoding="utf8").read()
TypeError: 'encoding' is an invalid keyword argument for this function
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

求救大佬们。

  • 写回答

1条回答 默认 最新

  • Lonelypatients° 2020-06-02 16:27
    关注

    还在使用python2 , python3 它不香吗?

    python setup.py egg_info 提示 让你看日志输出

    评论

报告相同问题?

悬赏问题

  • ¥100 求数学坐标画圆以及直线的算法
  • ¥100 c语言,请帮蒟蒻写一个题的范例作参考
  • ¥15 名为“Product”的列已属于此 DataTable
  • ¥15 安卓adb backup备份应用数据失败
  • ¥15 eclipse运行项目时遇到的问题
  • ¥15 关于#c##的问题:最近需要用CAT工具Trados进行一些开发
  • ¥15 南大pa1 小游戏没有界面,并且报了如下错误,尝试过换显卡驱动,但是好像不行
  • ¥15 自己瞎改改,结果现在又运行不了了
  • ¥15 链式存储应该如何解决
  • ¥15 没有证书,nginx怎么反向代理到只能接受https的公网网站