【问题标题】:why the python module did not found but install tell me already required为什么没有找到python模块但安装告诉我已经需要
【发布时间】:2021-08-07 16:04:52
【问题描述】:

我正在使用这个命令来安装 Python 模块:

~/source/pydolphin on  master! ⌚ 23:57:49
$ pip3 install -r requirements-pip.txt|grep celery                                                                                               ‹ruby-2.7.2›
Collecting celery==5.1.2
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/06/9d/61976ecc8caf0a03357bd174fa23c43b9dcd85f4c9667aa692de361cae84/celery-5.1.2-py3-none-any.whl (401 kB)
Requirement already satisfied: click<8.0,>=7.0 in /usr/local/anaconda3/lib/python3.7/site-packages (from celery==5.1.2->-r requirements-pip.txt (line 13)) (7.1.2)
Requirement already satisfied: prompt-toolkit in /usr/local/anaconda3/lib/python3.7/site-packages (from click-repl>=0.1.6->celery==5.1.2->-r requirements-pip.txt (line 13)) (3.0.5)
Requirement already satisfied: cached-property; python_version < "3.8" in /usr/local/anaconda3/lib/python3.7/site-packages (from kombu<6.0,>=5.1.0->celery==5.1.2->-r requirements-pip.txt (line 13)) (1.5.2)
Requirement already satisfied: wcwidth in /usr/local/anaconda3/lib/python3.7/site-packages (from prompt-toolkit->click-repl>=0.1.6->celery==5.1.2->-r requirements-pip.txt (line 13)) (0.2.5)
Installing collected packages: croniter, opencv-python, coverage, args, clint, mamba, click-didyoumean, click-repl, vine, click-plugins, amqp, kombu, billiard, celery, lxml, cssselect, itemadapter, w3lib, parsel, jmespath, itemloaders, queuelib, hpack, hyperframe, h2, PyDispatcher, protego, pyasn1, pyasn1-modules, service-identity, constantly, incremental, Automat, hyperlink, priority, Twisted, scrapy, apollo-client, jsonpickle

模块已安装。但是当我像这样显示模块时:

~/source/pydolphin on  master! ⌚ 23:56:06
$ pip3 show celery                                                                                                                               ‹ruby-2.7.2›
WARNING: Package(s) not found: celery

告诉我模块没有找到,为什么 pip3 告诉我模块已经需要?并且 pip3 没有使用 anaconda3 模块。如果没有使用 anaconda3 模块,pip3 应该使用它自己的模块缓存!!!

【问题讨论】:

  • pip3 install -r requirements-pip.txt 的完整输出是什么?我没有看到任何确认安装成功(尽管我不是 pip 专家)。

标签: python python-3.x pip


【解决方案1】:

当我使用 pip 下载 numpy 时,曾经发生过这种情况,但我使用的是带有 windows 的计算机,解决方案是将文件从一个文件夹移动到另一个文件夹。 Linux pc 上的解决方案可能会有所不同。也许这篇文章可以帮助你: Python pip install module is not found. How to link python to pip location?

【讨论】:

    猜你喜欢
    • 2020-12-04
    • 2013-08-04
    • 2020-11-14
    • 1970-01-01
    • 2020-08-29
    • 2021-01-31
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多