install pyquery on windows

2019-05-08 06:27发布

I want to install pyquery on windows. But i cant run setup.py install on the command line. Do you have any hint?

4条回答
Emotional °昔
2楼-- · 2019-05-08 06:41

I guess you don't have lxml or setuptools installed

setuptools http://pypi.python.org/pypi/setuptools/0.6c11

lxml http://pypi.python.org/pypi/lxml/2.2.2

Install them first and then try again, I just tried that, its working properly here.

查看更多
祖国的老花朵
3楼-- · 2019-05-08 06:43

SIMPLE WORKING SOLUTION:

I download the tar file here pyquery-1.2.13.tar.gz (https://pypi.python.org/pypi/pyquery#downloads)

I extracted them a folder pyquery-1.2.13 then i pasted myscript.py to this folder pyquery-1.2.13 in my script i have these lines at the very top to include pyquery module and it works!

import pyquery (this file is in pyquery-1.2.13 folder)

from pyquery import *

Done.

查看更多
Summer. ? 凉城
4楼-- · 2019-05-08 06:57

I could not install lxml on windows with either pip or easy_install. Complained "Unable to find vcvarsall.bat"

Tried installing Cygwin and MinGW but that was taking way too long

found out from raidsan's answer about unofficial precompiled windows binaries http://www.lfd.uci.edu/~gohlke/pythonlibs/ installed and works fine now

查看更多
我欲成王,谁敢阻挡
5楼-- · 2019-05-08 06:58

I'm using miniconda on Windows and here is how I installed pyQuery :

Download python miniconda from http://conda.pydata.org/miniconda.html (if you need many libraries at once, consider installing anadonda instead)

Then from the commandline prompt, run the following commands:

conda install lxml
conda install setuptools

Grab the lastest pyQuery source from https://codeload.github.com/gawel/pyquery/zip/master and unzip it to a directory.

Again from the commandline, go to this directory and run :

python setup.py install
查看更多
登录 后发表回答