To add alecxe to the answer, for Ubuntu / Debian systems, first install the dependencies (webkit, gtk2 and jswebkit)
sudo apt-get install python-jswebkit libwebkitgtk-1.0-0 python-webkit
sudo apt-get install python-gtk2 python-gnome2 python-glade2 python-gobject
virtualenv,
mkdir your-venv/lib/python2.7/dist-packages
ln -s /usr/lib/python2.7/dist-packages/gtk-2.0* lib/python2.7/dist-packages/
ln -s /usr/lib/python2.7/dist-packages/pygtk.pth lib/python2.7/dist-packages/
ln -s /usr/lib/python2.7/dist-packages/gobject/ lib/python2.7/dist-packages/
ln -s /usr/lib/python2.7/dist-packages/glib/ lib/python2.7/dist-packages/
ln -s /usr/lib/python2.7/dist-packages/cairo lib/python2.7/dist-packages/
ln -s /usr/lib/python2.7/dist-packages/webkit lib/python2.7/dist-packages/
ln -s /usr/lib/python2.7/dist-packages/jswebkit.so lib/python2.7/dist-packages/
, , ( )
python -c "import scrapy; print scrapy.__file__"
- Scrapy __init__.py. __init__.py
from twisted.internet import gtk2reactor
gtk2reactor.install()