【发布时间】:2015-11-25 15:31:09
【问题描述】:
有没有办法通过 pip 安装 xGoogle?如果是这样,我该怎么做?我已经尝试过:
$ pip install xGoogle
如果没有使用pip安装的方法,我可以通过easy-install来安装吗?
我的操作系统使用的是 Windows 10。
【问题讨论】:
标签: python-2.7 pip xgoogle
有没有办法通过 pip 安装 xGoogle?如果是这样,我该怎么做?我已经尝试过:
$ pip install xGoogle
如果没有使用pip安装的方法,我可以通过easy-install来安装吗?
我的操作系统使用的是 Windows 10。
【问题讨论】:
标签: python-2.7 pip xgoogle
您可以直接从它的repository 安装它:
$ git clone https://github.com/pkrumins/xgoogle
$ cd xgoogle
$ sudo python setup.py install
【讨论】:
在我的情况下,链接答案没有帮助。
在from xgoogle.search import GoogleSearch, SearchError 行中,xgoogle、GoogleSearch 和 SearchError 需要 Install package xgoogle、Install package GoogleSearch 和 Rename reference 用于 SearchError,但在 pip install xgoogle 命令执行期间发生错误:
Error: Could not find a version that satisfies the requirement xgoogle (from versions: none)
命令输出:
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. A future version of pip will drop support for Python 2.7. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
ERROR: Could not find a version that satisfies the requirement xgoogle (from versions: none)
ERROR: No matching distribution found for xgoogle
我从author's web page 下载了xgoogle.zip,将其解压缩并放入我的~/PycharmProjects/myproject/ 文件夹中。它适用于这个项目。
不过,xgoogle 包现在是dead。
【讨论】:
应该是:
$ git clone https://github.com/pkrumins/xgoogle
$ cd xgoogle
$ sudo python setup.py install
【讨论】: