Python 3.4 install lxml, pythonlxml

Source: Internet
Author: User

Python 3.4 install lxml, pythonlxml

To use Xpath in Python, you must inevitably import the lxml module.
However, one of the main problems facing Python is that it has two mainstream versions: 2.7 and 3.4.

2.7 is a relatively stable version, and many modules have excellent support on 2.7.
3.4 relatively speaking, I think it is more standard and standardized, such as the default exact division and print parentheses.
However, less than 3.4 US dollars is the poor support for some modules, such as scrapy and lxml.

In Python3.4, if pip directly installs lxml, a compiler error is reported. This problem may be improved in later versions. However, one feasible solution is:Download and install the lxml compiled versionTo skip the compilation process.

Download link
Switch to the corresponding directory after downloadingPip install file nameYou can.
In this way, you can use lxml in Python.

PS:

Copyright Disclaimer: This article is an original article by the blogger and cannot be reproduced without the permission of the blogger.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.