No module named lxml.html while running python script on Fedora
Question: I'm trying to run a python script on Fedora Server. I'm getting the following
error.

    
    
    /usr/bin/python report_generation.py
    Traceback (most recent call last):
    File "report_generation.py", line 9, in ?
    import lxml.html
    ImportError: No module named lxml.html
    

Doing some research, I found it needs python-lxml package to run the script.
This machine already have some lxml installations. But, I'm not able to make
this work.

    
    
    yum search libxml
    
    libxml2.i386 : Library providing XML and HTML support
    libxml2.x86_64 : Library providing XML and HTML support
    libxml2-devel.i386 : Libraries, includes, etc. to develop XML and HTML applications
    libxml2-devel.x86_64 : Libraries, includes, etc. to develop XML and HTML applications
    libxml2-python.x86_64 : Python bindings for the libxml2 library
    libxslt.i386 : Library providing the Gnome XSLT engine
    libxslt.x86_64 : Library providing the Gnome XSLT engine
    libxslt-devel.i386 : Libraries, includes, etc. to embed the Gnome XSLT engine
    libxslt-devel.x86_64 : Libraries, includes, etc. to embed the Gnome XSLT engine
    libxslt-python.x86_64 : Python bindings for the libxslt library
    

Also, it says all of them are up to date when I tried to install the packages.
For some reason, its not picking up the lxml module and throwing this error
while running the script. I'm new to both Linux and Python. Please provide me
any clue to debug this issue.


Answer: 
    sudo yum install python-lxml 
    

or

    
    
    sudo apt-get install python-lxml
    

