Scrapy will not run on my Ubuntu 14.04 giving the error:
Traceback (most recent call last):
File "/usr/bin/scrapy", line 5, in <module>
from pkg_resources import load_entry_point
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 2749, in <module>
working_set = WorkingSet._build_master()
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 444, in _build_master
ws.require(__requires__)
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 725, in require
needed = self.resolve(parse_requirements(requirements))
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 628, in resolve
raise DistributionNotFound(req)
pkg_resources.DistributionNotFound: service-identity
Timeline: I had Python 2.7.6 installed which came with Ubuntu 14.04. I upgraded to 2.7.9 which is currently my python -V. I started by downloaded scrapy from the website (scrapy.org) following their Ubuntu instructions, and I got the error code above when attempting to use scrapy. Then I went through every imaginable stackoverflow for pip being broken, scrapy being broken but no good.
pip upgrade did not work: pip broke. how to fix DistributionNotFound error?
This guy had almost the same error but no response: Python(Scrapy) unpredictable mistake with "import load_entry_point" He pointed to: Python & Scrapy: Issue with Scrapy version
I uninstalled all scrapy and reinstalled with pip (it was installing version Scrapy-1.0.3) and it initially failed but I upgraded some libraries (libffi & lxml) and the install worked with a sudo run. Same error remained when running scrappy.
Any chance anyone knows whats going on? Thanks