0

I'm trying to install the pyquery module, which requires lxml. Whenever I try to install the lxml module, though, it gets exactly this far:

$ sudo python3.7 -m pip install lxml
Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple
Collecting lxml
  Downloading https://files.pythonhosted.org/packages/16/4a/b085a04d6dad79aa5c00c65c9b2bbcb2c6c22e5ac341e7968e0ad2c57e2f/lxml-4.3.0.tar.gz (2.5MB)
    100% |████████████████████████████████| 2.5MB 1.2MB/s 
Installing collected packages: lxml
  Running setup.py install for lxml ... /

...and then the / stops spinning. If I leave it running for more than about a minute, the Pi freezes.

Since I'm using a different version of Python 3 than comes installed on the pi, sudo apt-get install python3-lxml doesn't work either (unless there's a way to get this working that I don't know about). Is there any way to get around this?

  • For Arm there is no binary package for your version Python, so pip will (should) try to compile the package. You may have to wait a bit longer than a couple of minutes before giving up. Alternatively you could try python3-lxml from the Raspbian Buster repo. Search the web on how to install single packages from a different repo. – Dirk Jan 12 at 18:27

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.