-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Using pip install -r requirements.txt does not install lxml #151
Comments
lxml is a native library, so you need at least build-essential and libxml2-dev (not sure about exact package names, so don't quote me on this). apt-get install python-lxml does not need those, because it's pre-built. So I suspect pip tried to install lxml (it works provided you have the correct deps installed, see make virtualenv ) but it failed due to being unable to compile the native library. Could you please check if that's the case or post the output of pip install -r requirements.txt here? |
@bernardATdiymut Just install libxml2-dev and then pip install lxml. pip freeze command will verify whether it is installed. |
I'm experiencing this issue still on a fresh install of Ubuntu 14.04 |
@brennannovak I don't think this is really solvable by using python packaging. I think the easiest way of solving this is building a deb-package (I added some code for this last year, but it probably doesn't work any more) and adding a |
Agree with Uli. Ultimately, cloning from github is a developer exercise, and developers have to be able to deal with dependencies and tricky builds at times. The only solution we have to this problem is to stop using lxml, which we can't do in the near term. Closing this, the issue will be addressed via. packaging. But thanks much for reporting & discussing! |
Hi!
[I may be presuming something incorrectly, but here goes...]
I cloned the repo and followed the pip install step from the readme, "pip install -r requirements.txt", to install the python requirements. It finished successfully.
I then tried to run mailpile using: Mailpile$ ./mp --set "my_from: name@domain.tld = MyName" --setup, and got:
Traceback (most recent call last):
File "./mp", line 7, in
from mailpile.app import Main
File "./mailpile/init.py", line 3, in
import mailpile.app
File "./mailpile/app.py", line 37, in
import lxml.html
ImportError: No module named lxml.html
I presume pip install was supposed to install python-lxml? Looking through requirements.txt shows:
$ cat requirements.txt
lxml==2.3.2
http://sourceforge.net/projects/py-gnupg/files/GnuPGInterface/0.3.2/GnuPGInterface-0.3.2.tar.gz
To fix this I installed it with apt-get install python-lxml.
Should lxml be defined differently in the requirements.txt file?
If so it should be changed, OR if pip install does NOT install lxml, then it should be stated clearly that you have to install it seperately, as the current wording gives the impression that pip install takes care of it.
Thanks.
The text was updated successfully, but these errors were encountered: