Fix warnings when building the docs
authorKevin Burke <kevin@twilio.com>
Sat, 28 Dec 2013 08:09:29 +0000 (00:09 -0800)
committerKevin Burke <kevin@twilio.com>
Sat, 28 Dec 2013 08:09:29 +0000 (00:09 -0800)
It may be nice to make builds fail if new documentation generates warnings, to
avoid these sorts of problems slipping in in the future.

docs/index.rst
docs/user/advanced.rst
requests/adapters.py
requests/models.py
requests/sessions.py

index 85e1172192cf2916c04437d301a0b65c5baa82ec..4b0ecfd48f2f8ff239102c6662a8d45cd0e4d5c1 100644 (file)
@@ -130,6 +130,5 @@ you.
    :maxdepth: 1
 
    dev/philosophy
-   dev/internals
    dev/todo
    dev/authors
index 3ff66d52d1cf7e5ed1d5ab16f5028d9ff4d399f3..a0565f2a717e40b51de4b2daffe2740aebe161fa 100644 (file)
@@ -300,7 +300,7 @@ Then, we can make a request using our Pizza Auth::
     >>> requests.get('http://pizzabin.org/admin', auth=PizzaAuth('kenneth'))
     <Response [200]>
 
-.. _streaming-requests
+.. _streaming-requests:
 
 Streaming Requests
 ------------------
index b62f64c85af6a0834198a1d1efd9fa8507a04009..ba468e887335cbb82d4080b1b1a92f909cf5c38c 100644 (file)
@@ -55,14 +55,16 @@ class HTTPAdapter(BaseAdapter):
 
     :param pool_connections: The number of urllib3 connection pools to cache.
     :param pool_maxsize: The maximum number of connections to save in the pool.
-    :param max_retries: The maximum number of retries each connection should attempt.
+    :param int max_retries: The maximum number of retries each connection
+        should attempt. Note, this applies only to failed connections and
+        timeouts, never to requests where the server returns a response.
     :param pool_block: Whether the connection pool should block for connections.
 
     Usage::
 
       >>> import requests
       >>> s = requests.Session()
-      >>> a = requests.adapters.HTTPAdapter()
+      >>> a = requests.adapters.HTTPAdapter(max_retries=3)
       >>> s.mount('http://', a)
     """
     __attrs__ = ['max_retries', 'config', '_pool_connections', '_pool_maxsize',
index 061c93b06ab58873a2ffbbed2285af271d1396ac..ae46a83185cdec139d332b06d02c892376e5eaf9 100644 (file)
@@ -526,7 +526,7 @@ class Response(object):
         self.headers = CaseInsensitiveDict()
 
         #: File-like object representation of response (for advanced usage).
-        #: Requires that ``stream=True` on the request.
+        #: Use of ``raw`` requires that ``stream=True`` be set on the request.
         # This requirement does not apply for use internally to Requests.
         self.raw = None
 
index 2aae6e4000ddaa2741d3996fcc905c4ca58651cb..db227ca379652c8aab8adfd444b3c8cff84b904b 100644 (file)
@@ -256,7 +256,7 @@ class Session(SessionRedirectMixin):
         :class:`Session`.
 
         :param request: :class:`Request` instance to prepare with this
-        session's settings.
+            session's settings.
         """
         cookies = request.cookies or {}