我的Python 2.7和我試圖用PyQuery,所以對於一個測試,我剛鍵入「進口PyQuery」,我得到了一個錯誤:Python/PyQuery:無法找到vcvarsall.bat?
Traceback (most recent call last):
File "C:\Users\Jacob\Documents\dupes.py", line 1, in <module>
import pyquery
File "C:\Python27\lib\site-packages\pyquery-1.2.1-py2.7.egg\pyquery\__init__.py", line 12, in <module>
from .pyquery import PyQuery
File "C:\Python27\lib\site-packages\pyquery-1.2.1-py2.7.egg\pyquery\pyquery.py", line 8, in <module>
from lxml import etree
ImportError: No module named lxml
於是我去到命令提示符並試圖安裝LXML ,但我得到了這個:
Building lxml version 2.3.5.
Building without Cython.
ERROR: 'xslt-config' is not recognized as an internal or external command,
operable program or batch file.
** make sure the development packages of libxml2 and libxslt are installed **
Using build configuration of libxslt
error: Setup script exited with error: Unable to find vcvarsall.bat
我真的不明白什麼是錯的或我應該做什麼......有人可以幫忙嗎?
謝謝。
編輯:
在迴應評論,我用簡單的安裝...
你是如何嘗試安裝lxml的? – jdi 2012-08-09 19:55:14