1

Good day! I'm pretty new to python/scrapy as in never tried it. I've been able to work through a lot of the issues I've come across but I'm stuck trying to resolve "Running setup.py bdist_wheel for lxml ... error" I can't seem to get past it. I've tried to "pip3 install lxml" but that fails. I could past the whole terminal text but that is almost 500 lines. What would be helpful to provide enough info to resolve.

OS 10.11.6

Any help would be great! I'm anxious to try out scrapy! Nick

Maybe I should enter my response here! :) I have been able to install other packages. I've started over a couple of times so I'm working in a "fresh" virtualenv

user3408397
  • 523
  • 1
  • 5
  • 14
  • What do the last 10 lines or so of the output say? Were you able to install other packages without issue? – tabbek Feb 18 '18 at 00:55
  • the last bit "install --record /var/folders/xg/xyrymrj94n97vdmb0yhv63m00000gn/T/pip-xcjjtpgv-record/install-record.txt --single-version-externally-managed --compile --install-headers /Users/iSagui/Virtualenvs/scrapy_env/bin/../include/site/python3.7/lxml" failed with error code 1 in /private/var/folders/xg/xyrymrj94n97vdmb0yhv63m00000gn/T/pip-build-o59glt2i/lxml/" – user3408397 Feb 18 '18 at 01:07
  • do you have a compiler installed? lxml dependencies? do the steps [here](https://stackoverflow.com/questions/30410030/python-install-lxml-on-mac-os-10-10-1) help? – tabbek Feb 18 '18 at 10:04
  • @tabbek looked at the steps you provided and I don't think they will help. I ran "softwareupdate --list" and there is nothing to update. I do notice that when trying to install scrapy lxml resources are being found. bombs out on building wheels "Running setup.py bdist_wheel for lxml ... error" – user3408397 Feb 18 '18 at 15:42
  • Did you double check that you have gcc installed? Getting the packages but failing to build would point towards not having dependencies, like the compiler gcc, installed. Alternatively, any difference in behavior when using 'easy_install' instead of pip? – tabbek Feb 18 '18 at 20:54
  • @tabbek yep that is installed. I believe it's version 4.2.1 – user3408397 Feb 18 '18 at 23:36
  • @tabbek I tried easy_install and it bombed. Could not find function xmlCheckVersion in library libxml2. Is libxml2 installed?. I did install xcode and command line tools. still cant get this installed. I do appreciate your efforts! – user3408397 Feb 19 '18 at 01:11
  • I have this working. Man, what a chore! I updated the OS to latest. Went to the app store and updated xcode. Needed to install cryptograpy (pip3.7 install cryptography --global-option=build_ext --global-option="-L/usr/local/opt/openssl/lib" --global-option="-I/usr/local/opt/openssl/include") and then it worked. Thank you @tabbek! – user3408397 Feb 19 '18 at 04:11

1 Answers1

0

from user stanac, async and await are keywords in python 3.7. so even after I was able to install scrapy successfully, i couldn't run bench or shell (testing install) without throwing errors. installed a virtualenv targeting 2.7 and installed and ran bench/shell with no issues.

user3408397
  • 523
  • 1
  • 5
  • 14