Commit Graph

3 Commits

Author SHA1 Message Date
Radu Voicilas 820dfb0495 Making the code more PEP8 compliant 2012-10-09 00:42:49 +03:00
Locker537 42d0a2169e Whitespace fixes following PEP8. 2012-08-16 17:38:35 -04:00
Shivaram Lingamneni 3c0b94047c address connection leak issue from #520
* prefetch now defaults to True, ensuring that by default, sockets
  are returned to the urllib3 connection pool on request end
* sessions now have a close() method, notifying urllib3 to close pooled
  connections
* the module-level API, e.g., `requests.get('http://www.google.com')`,
  explicitly closes its session when finished

When prefetch is False, the open socket becomes part of the state of the
Response object, and it's the client's responsibility to read the whole
body, at which point the socket will be returned to the pool.
2012-08-05 21:09:13 -07:00