gevent installation documentation
authorKenneth Reitz <me@kennethreitz.com>
Fri, 14 Oct 2011 01:50:04 +0000 (21:50 -0400)
committerKenneth Reitz <me@kennethreitz.com>
Fri, 14 Oct 2011 01:50:04 +0000 (21:50 -0400)
docs/user/advanced.rst
docs/user/install.rst
requests/models.py

index e8c812a8a7fe5dd4a1d9a82a8de8bdfec17285d7..9f0a68386a20e7857e406c5c3e0120a6e2835d7a 100644 (file)
@@ -50,7 +50,7 @@ Requests has first-class support for non-blocking i/o requests, powered
 by gevent. This allows you to send a bunch of HTTP requests at the same
 
 First, let's import the async module. Heads up — if you don't have
-**gevent** installed, this will fail.::
+`gevent <gevent>`_ this will fail::
 
     from requests import async
 
index dc4aa627cdf1dd69e0d344ccd76a73ee0dc57108..6179abdcf217649b112a2bc80d76f9e562ee5140 100644 (file)
@@ -54,3 +54,25 @@ Once you have a copy of the source, you can embed it in your Python package,
 or install it into your site-packages easily::
 
     $ python setup.py install
+
+.. _gevent:
+
+Installing Gevent
+-----------------
+
+If you are using the ``requests.async`` module for making concurrent
+requests, you need to install gevent.
+
+To install gevent, you'll need ``libevent``.
+
+OSX::
+
+    $ brew install libevent
+
+Ubuntu::
+
+    $ apt-get install libevent-dev
+
+Once you have ``libevent``, you can install ``gevent`` with ``pip``::
+
+    $ pip install gevent
\ No newline at end of file
index 8969c886de2d999ef1a5a12bc08cc31dd66377a8..a63c904cd9c450983b0bafddc099ba0ff7ca8251 100644 (file)
@@ -182,7 +182,6 @@ class Request(object):
                 response._close = resp.close
 
                 if self.cookiejar:
-
                     response.cookies = dict_from_cookiejar(self.cookiejar)