pip search 何时能重新上线?

https://status.python.org/ 公告的时间看,pip search 不能用已经十多天了:

Update - The XMLRPC Search endpoint is still disabled due to ongoing request volume. As of this update, there has been no reduction in inbound traffic to the endpoint from abusive IPs and we are unable to re-enable the endpoint, as it would immediately cause PyPI service to degrade again. We are working with the abuse contact at the owner of the IPs and trying to make contact with the maintainers of whatever tool is flooding us via other channels.

现在随便搜索一个包:

⋊> pip search <package>
ERROR: Exception:
Traceback (most recent call last):
  File "~/.pyenv/versions/3.6.5/lib/python3.6/site-packages/pip/_internal/cli/base_command.py", line 224, in _main
    status = self.run(options, args)
  File "~/.pyenv/versions/3.6.5/lib/python3.6/site-packages/pip/_internal/commands/search.py", line 62, in run
    pypi_hits = self.search(query, options)
  File "~/.pyenv/versions/3.6.5/lib/python3.6/site-packages/pip/_internal/commands/search.py", line 82, in search
    hits = pypi.search({'name': query, 'summary': query}, 'or')
  File "~/.pyenv/versions/3.6.5/lib/python3.6/xmlrpc/client.py", line 1112, in __call__
    return self.__send(self.__name, args)
  File "~/.pyenv/versions/3.6.5/lib/python3.6/xmlrpc/client.py", line 1452, in __request
    verbose=self.__verbose
  File "~/.pyenv/versions/3.6.5/lib/python3.6/site-packages/pip/_internal/network/xmlrpc.py", line 46, in request
    return self.parse_response(response.raw)
  File "~/.pyenv/versions/3.6.5/lib/python3.6/xmlrpc/client.py", line 1342, in parse_response
    return u.close()
  File "~/.pyenv/versions/3.6.5/lib/python3.6/xmlrpc/client.py", line 656, in close
    raise Fault(**self._stack[0])
xmlrpc.client.Fault: <Fault -32500: "RuntimeError: PyPI's XMLRPC API has been temporarily disabled due to unmanageable load and will be deprecated in the near future. See https://status.python.org/ for more information.">

好在 pip install 没问题,可以安装一个 pip_search 暂时代替搜索。

看起来像是pypi的某个关键api被临时停用了

谢谢楼主,都没注意到这个问题… pip_search看来不错

pip search 现在都还用不了。看来只能用 pip-search ,再在 .zshrc 中加个 alias。

alias pip='function _pip(){
    if [ $1 = "search" ]; then
        pip_search "$2";
    else pip "$@";
    fi;
};_pip'
1 个赞

covid-19 先结束,还是 pip search 先修复?

希望 Covid-19 快点结束(刚刚又被封2天,才放出来 :sweat_smile:), pip search 不修也罢,pip-search 界面更加好看。