HISTORY.md
This file
Path
HISTORY.md
1,623 lines · 47.4 KiB · Markdown
Last changed by
Merge pull request #4835 from requests/2.20.0Nate Prewittbefore adoption75bdc99
History of this fileTake it
historyKenneth Reitzbefore adoption5251882
lines 1–6why, one step back1Release History2===============34dev5---6Merge pull request #4765 from requests/encapsulate_urllib3_excNate Prewittbefore adoptiona6cd380
lines 7–8why, one step back7**Bugfixes**8Merge pull request #4835 from requests/2.20.0Nate Prewittbefore adoption75bdc99
lines 9–15why, one step back9- \[Short description of non-trivial change.\]10112.20.0 (2018-10-18)12-------------------1314**Bugfixes**15Merge pull request #4765 from requests/encapsulate_urllib3_excNate Prewittbefore adoptiona6cd380
lines 16–19why, one step back16- Content-Type header parsing is now case-insensitive (e.g.17 charset=utf8 v Charset=utf8).18- Fixed exception leak where certain redirect urls would raise19 uncaught urllib3 exceptions.Merge pull request #4835 from requests/2.20.0Nate Prewittbefore adoption75bdc99
lines 20–23why, one step back20- Requests removes Authorization header from requests redirected21 from https to http on the same hostname. (CVE-2018-18074)22- `should_bypass_proxies` now handles URIs without hostnames (e.g.23 files).historyKenneth Reitzbefore adoption5251882
line 24why, one step back24Merge pull request #4835 from requests/2.20.0Nate Prewittbefore adoption75bdc99
lines 25–31why, one step back25**Dependencies**2627- Requests now supports urllib3 v1.24.2829**Deprecations**3031- Requests has officially stopped support for Python 2.6.historyKenneth Reitzbefore adoption5251882
lines 32–669why, one step back32332.19.1 (2018-06-14)34-------------------3536**Bugfixes**3738- Fixed issue where status\_codes.py's `init` function failed trying39 to append to a `__doc__` value of `None`.40412.19.0 (2018-06-12)42-------------------4344**Improvements**4546- Warn user about possible slowdown when using cryptography version47 < 1.3.448- Check for invalid host in proxy URL, before forwarding request to49 adapter.50- Fragments are now properly maintained across redirects. (RFC723151 7.1.2)52- Removed use of cgi module to expedite library load time.53- Added support for SHA-256 and SHA-512 digest auth algorithms.54- Minor performance improvement to `Request.content`.55- Migrate to using collections.abc for 3.7 compatibility.5657**Bugfixes**5859- Parsing empty `Link` headers with `parse_header_links()` no longer60 return one bogus entry.61- Fixed issue where loading the default certificate bundle from a zip62 archive would raise an `IOError`.63- Fixed issue with unexpected `ImportError` on windows system which do64 not support `winreg` module.65- DNS resolution in proxy bypass no longer includes the username and66 password in the request. This also fixes the issue of DNS queries67 failing on macOS.68- Properly normalize adapter prefixes for url comparison.69- Passing `None` as a file pointer to the `files` param no longer70 raises an exception.71- Calling `copy` on a `RequestsCookieJar` will now preserve the cookie72 policy correctly.7374**Dependencies**7576- We now support idna v2.7.77- We now support urllib3 v1.23.78792.18.4 (2017-08-15)80-------------------8182**Improvements**8384- Error messages for invalid headers now include the header name for85 easier debugging8687**Dependencies**8889- We now support idna v2.6.90912.18.3 (2017-08-02)92-------------------9394**Improvements**9596- Running `$ python -m requests.help` now includes the installed97 version of idna.9899**Bugfixes**100101- Fixed issue where Requests would raise `ConnectionError` instead of102 `SSLError` when encountering SSL problems when using urllib3 v1.22.1031042.18.2 (2017-07-25)105-------------------106107**Bugfixes**108109- `requests.help` no longer fails on Python 2.6 due to the absence of110 `ssl.OPENSSL_VERSION_NUMBER`.111112**Dependencies**113114- We now support urllib3 v1.22.1151162.18.1 (2017-06-14)117-------------------118119**Bugfixes**120121- Fix an error in the packaging whereby the `*.whl` contained122 incorrect data that regressed the fix in v2.17.3.1231242.18.0 (2017-06-14)125-------------------126127**Improvements**128129- `Response` is now a context manager, so can be used directly in a130 `with` statement without first having to be wrapped by131 `contextlib.closing()`.132133**Bugfixes**134135- Resolve installation failure if multiprocessing is not available136- Resolve tests crash if multiprocessing is not able to determine the137 number of CPU cores138- Resolve error swallowing in utils set\_environ generator1391402.17.3 (2017-05-29)141-------------------142143**Improvements**144145- Improved `packages` namespace identity support, for monkeypatching146 libraries.1471482.17.2 (2017-05-29)149-------------------150151**Improvements**152153- Improved `packages` namespace identity support, for monkeypatching154 libraries.1551562.17.1 (2017-05-29)157-------------------158159**Improvements**160161- Improved `packages` namespace identity support, for monkeypatching162 libraries.1631642.17.0 (2017-05-29)165-------------------166167**Improvements**168169- Removal of the 301 redirect cache. This improves thread-safety.1701712.16.5 (2017-05-28)172-------------------173174- Improvements to `$ python -m requests.help`.1751762.16.4 (2017-05-27)177-------------------178179- Introduction of the `$ python -m requests.help` command, for180 debugging with maintainers!1811822.16.3 (2017-05-27)183-------------------184185- Further restored the `requests.packages` namespace for compatibility186 reasons.1871882.16.2 (2017-05-27)189-------------------190191- Further restored the `requests.packages` namespace for compatibility192 reasons.193194No code modification (noted below) should be necessary any longer.1951962.16.1 (2017-05-27)197-------------------198199- Restored the `requests.packages` namespace for compatibility200 reasons.201- Bugfix for `urllib3` version parsing.202203**Note**: code that was written to import against the204`requests.packages` namespace previously will have to import code that205rests at this module-level now.206207For example:208209 from requests.packages.urllib3.poolmanager import PoolManager210211Will need to be re-written to be:212213 from requests.packages import urllib3214 urllib3.poolmanager.PoolManager215216Or, even better:217218 from urllib3.poolmanager import PoolManager2192202.16.0 (2017-05-26)221-------------------222223- Unvendor ALL the things!2242252.15.1 (2017-05-26)226-------------------227228- Everyone makes mistakes.2292302.15.0 (2017-05-26)231-------------------232233**Improvements**234235- Introduction of the `Response.next` property, for getting the next236 `PreparedResponse` from a redirect chain (when237 `allow_redirects=False`).238- Internal refactoring of `__version__` module.239240**Bugfixes**241242- Restored once-optional parameter for243 `requests.utils.get_environ_proxies()`.2442452.14.2 (2017-05-10)246-------------------247248**Bugfixes**249250- Changed a less-than to an equal-to and an or in the dependency251 markers to widen compatibility with older setuptools releases.2522532.14.1 (2017-05-09)254-------------------255256**Bugfixes**257258- Changed the dependency markers to widen compatibility with older pip259 releases.2602612.14.0 (2017-05-09)262-------------------263264**Improvements**265266- It is now possible to pass `no_proxy` as a key to the `proxies`267 dictionary to provide handling similar to the `NO_PROXY` environment268 variable.269- When users provide invalid paths to certificate bundle files or270 directories Requests now raises `IOError`, rather than failing at271 the time of the HTTPS request with a fairly inscrutable certificate272 validation error.273- The behavior of `SessionRedirectMixin` was slightly altered.274 `resolve_redirects` will now detect a redirect by calling275 `get_redirect_target(response)` instead of directly querying276 `Response.is_redirect` and `Response.headers['location']`. Advanced277 users will be able to process malformed redirects more easily.278- Changed the internal calculation of elapsed request time to have279 higher resolution on Windows.280- Added `win_inet_pton` as conditional dependency for the `[socks]`281 extra on Windows with Python 2.7.282- Changed the proxy bypass implementation on Windows: the proxy bypass283 check doesn't use forward and reverse DNS requests anymore284- URLs with schemes that begin with `http` but are not `http` or285 `https` no longer have their host parts forced to lowercase.286287**Bugfixes**288289- Much improved handling of non-ASCII `Location` header values in290 redirects. Fewer `UnicodeDecodeErrors` are encountered on Python 2,291 and Python 3 now correctly understands that Latin-1 is unlikely to292 be the correct encoding.293- If an attempt to `seek` file to find out its length fails, we now294 appropriately handle that by aborting our content-length295 calculations.296- Restricted `HTTPDigestAuth` to only respond to auth challenges made297 on 4XX responses, rather than to all auth challenges.298- Fixed some code that was firing `DeprecationWarning` on Python 3.6.299- The dismayed person emoticon (`/o\\`) no longer has a big head. I'm300 sure this is what you were all worrying about most.301302**Miscellaneous**303304- Updated bundled urllib3 to v1.21.1.305- Updated bundled chardet to v3.0.2.306- Updated bundled idna to v2.5.307- Updated bundled certifi to 2017.4.17.3083092.13.0 (2017-01-24)310-------------------311312**Features**313314- Only load the `idna` library when we've determined we need it. This315 will save some memory for users.316317**Miscellaneous**318319- Updated bundled urllib3 to 1.20.320- Updated bundled idna to 2.2.3213222.12.5 (2017-01-18)323-------------------324325**Bugfixes**326327- Fixed an issue with JSON encoding detection, specifically detecting328 big-endian UTF-32 with BOM.3293302.12.4 (2016-12-14)331-------------------332333**Bugfixes**334335- Fixed regression from 2.12.2 where non-string types were rejected in336 the basic auth parameters. While support for this behaviour has been337 readded, the behaviour is deprecated and will be removed in the338 future.3393402.12.3 (2016-12-01)341-------------------342343**Bugfixes**344345- Fixed regression from v2.12.1 for URLs with schemes that begin with346 "http". These URLs have historically been processed as though they347 were HTTP-schemed URLs, and so have had parameters added. This was348 removed in v2.12.2 in an overzealous attempt to resolve problems349 with IDNA-encoding those URLs. This change was reverted: the other350 fixes for IDNA-encoding have been judged to be sufficient to return351 to the behaviour Requests had before v2.12.0.3523532.12.2 (2016-11-30)354-------------------355356**Bugfixes**357358- Fixed several issues with IDNA-encoding URLs that are technically359 invalid but which are widely accepted. Requests will now attempt to360 IDNA-encode a URL if it can but, if it fails, and the host contains361 only ASCII characters, it will be passed through optimistically.362 This will allow users to opt-in to using IDNA2003 themselves if they363 want to, and will also allow technically invalid but still common364 hostnames.365- Fixed an issue where URLs with leading whitespace would raise366 `InvalidSchema` errors.367- Fixed an issue where some URLs without the HTTP or HTTPS schemes368 would still have HTTP URL preparation applied to them.369- Fixed an issue where Unicode strings could not be used in basic370 auth.371- Fixed an issue encountered by some Requests plugins where372 constructing a Response object would cause `Response.content` to373 raise an `AttributeError`.3743752.12.1 (2016-11-16)376-------------------377378**Bugfixes**379380- Updated setuptools 'security' extra for the new PyOpenSSL backend in381 urllib3.382383**Miscellaneous**384385- Updated bundled urllib3 to 1.19.1.3863872.12.0 (2016-11-15)388-------------------389390**Improvements**391392- Updated support for internationalized domain names from IDNA2003 to393 IDNA2008. This updated support is required for several forms of IDNs394 and is mandatory for .de domains.395- Much improved heuristics for guessing content lengths: Requests will396 no longer read an entire `StringIO` into memory.397- Much improved logic for recalculating `Content-Length` headers for398 `PreparedRequest` objects.399- Improved tolerance for file-like objects that have no `tell` method400 but do have a `seek` method.401- Anything that is a subclass of `Mapping` is now treated like a402 dictionary by the `data=` keyword argument.403- Requests now tolerates empty passwords in proxy credentials, rather404 than stripping the credentials.405- If a request is made with a file-like object as the body and that406 request is redirected with a 307 or 308 status code, Requests will407 now attempt to rewind the body object so it can be replayed.408409**Bugfixes**410411- When calling `response.close`, the call to `close` will be412 propagated through to non-urllib3 backends.413- Fixed issue where the `ALL_PROXY` environment variable would be414 preferred over scheme-specific variables like `HTTP_PROXY`.415- Fixed issue where non-UTF8 reason phrases got severely mangled by416 falling back to decoding using ISO 8859-1 instead.417- Fixed a bug where Requests would not correctly correlate cookies set418 when using custom Host headers if those Host headers did not use the419 native string type for the platform.420421**Miscellaneous**422423- Updated bundled urllib3 to 1.19.424- Updated bundled certifi certs to 2016.09.26.4254262.11.1 (2016-08-17)427-------------------428429**Bugfixes**430431- Fixed a bug when using `iter_content` with `decode_unicode=True` for432 streamed bodies would raise `AttributeError`. This bug was433 introduced in 2.11.434- Strip Content-Type and Transfer-Encoding headers from the header435 block when following a redirect that transforms the verb from436 POST/PUT to GET.4374382.11.0 (2016-08-08)439-------------------440441**Improvements**442443- Added support for the `ALL_PROXY` environment variable.444- Reject header values that contain leading whitespace or newline445 characters to reduce risk of header smuggling.446447**Bugfixes**448449- Fixed occasional `TypeError` when attempting to decode a JSON450 response that occurred in an error case. Now correctly returns a451 `ValueError`.452- Requests would incorrectly ignore a non-CIDR IP address in the453 `NO_PROXY` environment variables: Requests now treats it as a454 specific IP.455- Fixed a bug when sending JSON data that could cause us to encounter456 obscure OpenSSL errors in certain network conditions (yes, really).457- Added type checks to ensure that `iter_content` only accepts458 integers and `None` for chunk sizes.459- Fixed issue where responses whose body had not been fully consumed460 would have the underlying connection closed but not returned to the461 connection pool, which could cause Requests to hang in situations462 where the `HTTPAdapter` had been configured to use a blocking463 connection pool.464465**Miscellaneous**466467- Updated bundled urllib3 to 1.16.468- Some previous releases accidentally accepted non-strings as469 acceptable header values. This release does not.4704712.10.0 (2016-04-29)472-------------------473474**New Features**475476- SOCKS Proxy Support! (requires PySocks;477 `$ pip install requests[socks]`)478479**Miscellaneous**480481- Updated bundled urllib3 to 1.15.1.4824832.9.2 (2016-04-29)484------------------485486**Improvements**487488- Change built-in CaseInsensitiveDict (used for headers) to use489 OrderedDict as its underlying datastore.490491**Bugfixes**492493- Don't use redirect\_cache if allow\_redirects=False494- When passed objects that throw exceptions from `tell()`, send them495 via chunked transfer encoding instead of failing.496- Raise a ProxyError for proxy related connection issues.4974982.9.1 (2015-12-21)499------------------500501**Bugfixes**502503- Resolve regression introduced in 2.9.0 that made it impossible to504 send binary strings as bodies in Python 3.505- Fixed errors when calculating cookie expiration dates in certain506 locales.507508**Miscellaneous**509510- Updated bundled urllib3 to 1.13.1.5115122.9.0 (2015-12-15)513------------------514515**Minor Improvements** (Backwards compatible)516517- The `verify` keyword argument now supports being passed a path to a518 directory of CA certificates, not just a single-file bundle.519- Warnings are now emitted when sending files opened in text mode.520- Added the 511 Network Authentication Required status code to the521 status code registry.522523**Bugfixes**524525- For file-like objects that are not seeked to the very beginning, we526 now send the content length for the number of bytes we will actually527 read, rather than the total size of the file, allowing partial file528 uploads.529- When uploading file-like objects, if they are empty or have no530 obvious content length we set `Transfer-Encoding: chunked` rather531 than `Content-Length: 0`.532- We correctly receive the response in buffered mode when uploading533 chunked bodies.534- We now handle being passed a query string as a bytestring on Python535 3, by decoding it as UTF-8.536- Sessions are now closed in all cases (exceptional and not) when537 using the functional API rather than leaking and waiting for the538 garbage collector to clean them up.539- Correctly handle digest auth headers with a malformed `qop`540 directive that contains no token, by treating it the same as if no541 `qop` directive was provided at all.542- Minor performance improvements when removing specific cookies by543 name.544545**Miscellaneous**546547- Updated urllib3 to 1.13.5485492.8.1 (2015-10-13)550------------------551552**Bugfixes**553554- Update certificate bundle to match `certifi` 2015.9.6.2's weak555 certificate bundle.556- Fix a bug in 2.8.0 where requests would raise `ConnectTimeout`557 instead of `ConnectionError`558- When using the PreparedRequest flow, requests will now correctly559 respect the `json` parameter. Broken in 2.8.0.560- When using the PreparedRequest flow, requests will now correctly561 handle a Unicode-string method name on Python 2. Broken in 2.8.0.5625632.8.0 (2015-10-05)564------------------565566**Minor Improvements** (Backwards Compatible)567568- Requests now supports per-host proxies. This allows the `proxies`569 dictionary to have entries of the form570 `{'<scheme>://<hostname>': '<proxy>'}`. Host-specific proxies will571 be used in preference to the previously-supported scheme-specific572 ones, but the previous syntax will continue to work.573- `Response.raise_for_status` now prints the URL that failed as part574 of the exception message.575- `requests.utils.get_netrc_auth` now takes an `raise_errors` kwarg,576 defaulting to `False`. When `True`, errors parsing `.netrc` files577 cause exceptions to be thrown.578- Change to bundled projects import logic to make it easier to579 unbundle requests downstream.580- Changed the default User-Agent string to avoid leaking data on581 Linux: now contains only the requests version.582583**Bugfixes**584585- The `json` parameter to `post()` and friends will now only be used586 if neither `data` nor `files` are present, consistent with the587 documentation.588- We now ignore empty fields in the `NO_PROXY` environment variable.589- Fixed problem where `httplib.BadStatusLine` would get raised if590 combining `stream=True` with `contextlib.closing`.591- Prevented bugs where we would attempt to return the same connection592 back to the connection pool twice when sending a Chunked body.593- Miscellaneous minor internal changes.594- Digest Auth support is now thread safe.595596**Updates**597598- Updated urllib3 to 1.12.5996002.7.0 (2015-05-03)601------------------602603This is the first release that follows our new release process. For604more, see [our605documentation](http://docs.python-requests.org/en/latest/community/release-process/).606607**Bugfixes**608609- Updated urllib3 to 1.10.4, resolving several bugs involving chunked610 transfer encoding and response framing.6116122.6.2 (2015-04-23)613------------------614615**Bugfixes**616617- Fix regression where compressed data that was sent as chunked data618 was not properly decompressed. (\#2561)6196202.6.1 (2015-04-22)621------------------622623**Bugfixes**624625- Remove VendorAlias import machinery introduced in v2.5.2.626- Simplify the PreparedRequest.prepare API: We no longer require the627 user to pass an empty list to the hooks keyword argument. (c.f.628 \#2552)629- Resolve redirects now receives and forwards all of the original630 arguments to the adapter. (\#2503)631- Handle UnicodeDecodeErrors when trying to deal with a unicode URL632 that cannot be encoded in ASCII. (\#2540)633- Populate the parsed path of the URI field when performing Digest634 Authentication. (\#2426)635- Copy a PreparedRequest's CookieJar more reliably when it is not an636 instance of RequestsCookieJar. (\#2527)6376382.6.0 (2015-03-14)639------------------640641**Bugfixes**642643- CVE-2015-2296: Fix handling of cookies on redirect. Previously a644 cookie without a host value set would use the hostname for the645 redirected URL exposing requests users to session fixation attacks646 and potentially cookie stealing. This was disclosed privately by647 Matthew Daley of [BugFuzz](https://bugfuzz.com). This affects all648 versions of requests from v2.1.0 to v2.5.3 (inclusive on both ends).649- Fix error when requests is an `install_requires` dependency and650 `python setup.py test` is run. (\#2462)651- Fix error when urllib3 is unbundled and requests continues to use652 the vendored import location.653- Include fixes to `urllib3`'s header handling.654- Requests' handling of unvendored dependencies is now more655 restrictive.656657**Features and Improvements**658659- Support bytearrays when passed as parameters in the `files`660 argument. (\#2468)661- Avoid data duplication when creating a request with `str`, `bytes`,662 or `bytearray` input to the `files` argument.6636642.5.3 (2015-02-24)665------------------666667**Bugfixes**668669- Revert changes to our vendored certificate bundle. For more contextMerge pull request #4805 from jdufresne/httpsNate Prewittbefore adoptionff0c325
line 670why, one step back670 see (\#2455, \#2456, and <https://bugs.python.org/issue23476>)historyKenneth Reitzbefore adoption5251882
lines 671–1623why, one step back6716722.5.2 (2015-02-23)673------------------674675**Features and Improvements**676677- Add sha256 fingerprint support.678 ([shazow/urllib3\#540](https://github.com/shazow/urllib3/pull/540))679- Improve the performance of headers.680 ([shazow/urllib3\#544](https://github.com/shazow/urllib3/pull/544))681682**Bugfixes**683684- Copy pip's import machinery. When downstream redistributors remove685 requests.packages.urllib3 the import machinery will continue to let686 those same symbols work. Example usage in requests' documentation687 and 3rd-party libraries relying on the vendored copies of urllib3688 will work without having to fallback to the system urllib3.689- Attempt to quote parts of the URL on redirect if unquoting and then690 quoting fails. (\#2356)691- Fix filename type check for multipart form-data uploads. (\#2411)692- Properly handle the case where a server issuing digest693 authentication challenges provides both auth and auth-int694 qop-values. (\#2408)695- Fix a socket leak.696 ([shazow/urllib3\#549](https://github.com/shazow/urllib3/pull/549))697- Fix multiple `Set-Cookie` headers properly.698 ([shazow/urllib3\#534](https://github.com/shazow/urllib3/pull/534))699- Disable the built-in hostname verification.700 ([shazow/urllib3\#526](https://github.com/shazow/urllib3/pull/526))701- Fix the behaviour of decoding an exhausted stream.702 ([shazow/urllib3\#535](https://github.com/shazow/urllib3/pull/535))703704**Security**705706- Pulled in an updated `cacert.pem`.707- Drop RC4 from the default cipher list.708 ([shazow/urllib3\#551](https://github.com/shazow/urllib3/pull/551))7097102.5.1 (2014-12-23)711------------------712713**Behavioural Changes**714715- Only catch HTTPErrors in raise\_for\_status (\#2382)716717**Bugfixes**718719- Handle LocationParseError from urllib3 (\#2344)720- Handle file-like object filenames that are not strings (\#2379)721- Unbreak HTTPDigestAuth handler. Allow new nonces to be negotiated722 (\#2389)7237242.5.0 (2014-12-01)725------------------726727**Improvements**728729- Allow usage of urllib3's Retry object with HTTPAdapters (\#2216)730- The `iter_lines` method on a response now accepts a delimiter with731 which to split the content (\#2295)732733**Behavioural Changes**734735- Add deprecation warnings to functions in requests.utils that will be736 removed in 3.0 (\#2309)737- Sessions used by the functional API are always closed (\#2326)738- Restrict requests to HTTP/1.1 and HTTP/1.0 (stop accepting HTTP/0.9)739 (\#2323)740741**Bugfixes**742743- Only parse the URL once (\#2353)744- Allow Content-Length header to always be overridden (\#2332)745- Properly handle files in HTTPDigestAuth (\#2333)746- Cap redirect\_cache size to prevent memory abuse (\#2299)747- Fix HTTPDigestAuth handling of redirects after authenticating748 successfully (\#2253)749- Fix crash with custom method parameter to Session.request (\#2317)750- Fix how Link headers are parsed using the regular expression library751 (\#2271)752753**Documentation**754755- Add more references for interlinking (\#2348)756- Update CSS for theme (\#2290)757- Update width of buttons and sidebar (\#2289)758- Replace references of Gittip with Gratipay (\#2282)759- Add link to changelog in sidebar (\#2273)7607612.4.3 (2014-10-06)762------------------763764**Bugfixes**765766- Unicode URL improvements for Python 2.767- Re-order JSON param for backwards compat.768- Automatically defrag authentication schemes from host/pass URIs.769 ([\#2249](https://github.com/requests/requests/issues/2249))7707712.4.2 (2014-10-05)772------------------773774**Improvements**775776- FINALLY! Add json parameter for uploads!777 ([\#2258](https://github.com/requests/requests/pull/2258))778- Support for bytestring URLs on Python 3.x779 ([\#2238](https://github.com/requests/requests/pull/2238))780781**Bugfixes**782783- Avoid getting stuck in a loop784 ([\#2244](https://github.com/requests/requests/pull/2244))785- Multiple calls to iter\* fail with unhelpful error.786 ([\#2240](https://github.com/requests/requests/issues/2240),787 [\#2241](https://github.com/requests/requests/issues/2241))788789**Documentation**790791- Correct redirection introduction792 ([\#2245](https://github.com/requests/requests/pull/2245/))793- Added example of how to send multiple files in one request.794 ([\#2227](https://github.com/requests/requests/pull/2227/))795- Clarify how to pass a custom set of CAs796 ([\#2248](https://github.com/requests/requests/pull/2248/))7977982.4.1 (2014-09-09)799------------------800801- Now has a "security" package extras set,802 `$ pip install requests[security]`803- Requests will now use Certifi if it is available.804- Capture and re-raise urllib3 ProtocolError805- Bugfix for responses that attempt to redirect to themselves forever806 (wtf?).8078082.4.0 (2014-08-29)809------------------810811**Behavioral Changes**812813- `Connection: keep-alive` header is now sent automatically.814815**Improvements**816817- Support for connect timeouts! Timeout now accepts a tuple (connect,818 read) which is used to set individual connect and read timeouts.819- Allow copying of PreparedRequests without headers/cookies.820- Updated bundled urllib3 version.821- Refactored settings loading from environment -- new822 Session.merge\_environment\_settings.823- Handle socket errors in iter\_content.8248252.3.0 (2014-05-16)826------------------827828**API Changes**829830- New `Response` property `is_redirect`, which is true when the831 library could have processed this response as a redirection (whether832 or not it actually did).833- The `timeout` parameter now affects requests with both `stream=True`834 and `stream=False` equally.835- The change in v2.0.0 to mandate explicit proxy schemes has been836 reverted. Proxy schemes now default to `http://`.837- The `CaseInsensitiveDict` used for HTTP headers now behaves like a838 normal dictionary when references as string or viewed in the839 interpreter.840841**Bugfixes**842843- No longer expose Authorization or Proxy-Authorization headers on844 redirect. Fix CVE-2014-1829 and CVE-2014-1830 respectively.845- Authorization is re-evaluated each redirect.846- On redirect, pass url as native strings.847- Fall-back to autodetected encoding for JSON when Unicode detection848 fails.849- Headers set to `None` on the `Session` are now correctly not sent.850- Correctly honor `decode_unicode` even if it wasn't used earlier in851 the same response.852- Stop advertising `compress` as a supported Content-Encoding.853- The `Response.history` parameter is now always a list.854- Many, many `urllib3` bugfixes.8558562.2.1 (2014-01-23)857------------------858859**Bugfixes**860861- Fixes incorrect parsing of proxy credentials that contain a literal862 or encoded '\#' character.863- Assorted urllib3 fixes.8648652.2.0 (2014-01-09)866------------------867868**API Changes**869870- New exception: `ContentDecodingError`. Raised instead of `urllib3`871 `DecodeError` exceptions.872873**Bugfixes**874875- Avoid many many exceptions from the buggy implementation of876 `proxy_bypass` on OS X in Python 2.6.877- Avoid crashing when attempting to get authentication credentials878 from \~/.netrc when running as a user without a home directory.879- Use the correct pool size for pools of connections to proxies.880- Fix iteration of `CookieJar` objects.881- Ensure that cookies are persisted over redirect.882- Switch back to using chardet, since it has merged with charade.8838842.1.0 (2013-12-05)885------------------886887- Updated CA Bundle, of course.888- Cookies set on individual Requests through a `Session` (e.g. via889 `Session.get()`) are no longer persisted to the `Session`.890- Clean up connections when we hit problems during chunked upload,891 rather than leaking them.892- Return connections to the pool when a chunked upload is successful,893 rather than leaking it.894- Match the HTTPbis recommendation for HTTP 301 redirects.895- Prevent hanging when using streaming uploads and Digest Auth when a896 401 is received.897- Values of headers set by Requests are now always the native string898 type.899- Fix previously broken SNI support.900- Fix accessing HTTP proxies using proxy authentication.901- Unencode HTTP Basic usernames and passwords extracted from URLs.902- Support for IP address ranges for no\_proxy environment variable903- Parse headers correctly when users override the default `Host:`904 header.905- Avoid munging the URL in case of case-sensitive servers.906- Looser URL handling for non-HTTP/HTTPS urls.907- Accept unicode methods in Python 2.6 and 2.7.908- More resilient cookie handling.909- Make `Response` objects pickleable.910- Actually added MD5-sess to Digest Auth instead of pretending to like911 last time.912- Updated internal urllib3.913- Fixed @Lukasa's lack of taste.9149152.0.1 (2013-10-24)916------------------917918- Updated included CA Bundle with new mistrusts and automated process919 for the future920- Added MD5-sess to Digest Auth921- Accept per-file headers in multipart file POST messages.922- Fixed: Don't send the full URL on CONNECT messages.923- Fixed: Correctly lowercase a redirect scheme.924- Fixed: Cookies not persisted when set via functional API.925- Fixed: Translate urllib3 ProxyError into a requests ProxyError926 derived from ConnectionError.927- Updated internal urllib3 and chardet.9289292.0.0 (2013-09-24)930------------------931932**API Changes:**933934- Keys in the Headers dictionary are now native strings on all Python935 versions, i.e. bytestrings on Python 2, unicode on Python 3.936- Proxy URLs now *must* have an explicit scheme. A `MissingSchema`937 exception will be raised if they don't.938- Timeouts now apply to read time if `Stream=False`.939- `RequestException` is now a subclass of `IOError`, not940 `RuntimeError`.941- Added new method to `PreparedRequest` objects:942 `PreparedRequest.copy()`.943- Added new method to `Session` objects: `Session.update_request()`.944 This method updates a `Request` object with the data (e.g. cookies)945 stored on the `Session`.946- Added new method to `Session` objects: `Session.prepare_request()`.947 This method updates and prepares a `Request` object, and returns the948 corresponding `PreparedRequest` object.949- Added new method to `HTTPAdapter` objects:950 `HTTPAdapter.proxy_headers()`. This should not be called directly,951 but improves the subclass interface.952- `httplib.IncompleteRead` exceptions caused by incorrect chunked953 encoding will now raise a Requests `ChunkedEncodingError` instead.954- Invalid percent-escape sequences now cause a Requests `InvalidURL`955 exception to be raised.956- HTTP 208 no longer uses reason phrase `"im_used"`. Correctly uses957 `"already_reported"`.958- HTTP 226 reason added (`"im_used"`).959960**Bugfixes:**961962- Vastly improved proxy support, including the CONNECT verb. Special963 thanks to the many contributors who worked towards this improvement.964- Cookies are now properly managed when 401 authentication responses965 are received.966- Chunked encoding fixes.967- Support for mixed case schemes.968- Better handling of streaming downloads.969- Retrieve environment proxies from more locations.970- Minor cookies fixes.971- Improved redirect behaviour.972- Improved streaming behaviour, particularly for compressed data.973- Miscellaneous small Python 3 text encoding bugs.974- `.netrc` no longer overrides explicit auth.975- Cookies set by hooks are now correctly persisted on Sessions.976- Fix problem with cookies that specify port numbers in their host977 field.978- `BytesIO` can be used to perform streaming uploads.979- More generous parsing of the `no_proxy` environment variable.980- Non-string objects can be passed in data values alongside files.9819821.2.3 (2013-05-25)983------------------984985- Simple packaging fix9869871.2.2 (2013-05-23)988------------------989990- Simple packaging fix9919921.2.1 (2013-05-20)993------------------994995- 301 and 302 redirects now change the verb to GET for all verbs, not996 just POST, improving browser compatibility.997- Python 3.3.2 compatibility998- Always percent-encode location headers999- Fix connection adapter matching to be most-specific first1000- new argument to the default connection adapter for passing a block1001 argument1002- prevent a KeyError when there's no link headers100310041.2.0 (2013-03-31)1005------------------10061007- Fixed cookies on sessions and on requests1008- Significantly change how hooks are dispatched - hooks now receive1009 all the arguments specified by the user when making a request so1010 hooks can make a secondary request with the same parameters. This is1011 especially necessary for authentication handler authors1012- certifi support was removed1013- Fixed bug where using OAuth 1 with body `signature_type` sent no1014 data1015- Major proxy work thanks to @Lukasa including parsing of proxy1016 authentication from the proxy url1017- Fix DigestAuth handling too many 401s1018- Update vendored urllib3 to include SSL bug fixes1019- Allow keyword arguments to be passed to `json.loads()` via the1020 `Response.json()` method1021- Don't send `Content-Length` header by default on `GET` or `HEAD`1022 requests1023- Add `elapsed` attribute to `Response` objects to time how long a1024 request took.1025- Fix `RequestsCookieJar`1026- Sessions and Adapters are now picklable, i.e., can be used with the1027 multiprocessing library1028- Update charade to version 1.0.310291030The change in how hooks are dispatched will likely cause a great deal of1031issues.103210331.1.0 (2013-01-10)1034------------------10351036- CHUNKED REQUESTS1037- Support for iterable response bodies1038- Assume servers persist redirect params1039- Allow explicit content types to be specified for file data1040- Make merge\_kwargs case-insensitive when looking up keys104110421.0.3 (2012-12-18)1043------------------10441045- Fix file upload encoding bug1046- Fix cookie behavior104710481.0.2 (2012-12-17)1049------------------10501051- Proxy fix for HTTPAdapter.105210531.0.1 (2012-12-17)1054------------------10551056- Cert verification exception bug.1057- Proxy fix for HTTPAdapter.105810591.0.0 (2012-12-17)1060------------------10611062- Massive Refactor and Simplification1063- Switch to Apache 2.0 license1064- Swappable Connection Adapters1065- Mountable Connection Adapters1066- Mutable ProcessedRequest chain1067- /s/prefetch/stream1068- Removal of all configuration1069- Standard library logging1070- Make Response.json() callable, not property.1071- Usage of new charade project, which provides python 2 and 31072 simultaneous chardet.1073- Removal of all hooks except 'response'1074- Removal of all authentication helpers (OAuth, Kerberos)10751076This is not a backwards compatible change.107710780.14.2 (2012-10-27)1079-------------------10801081- Improved mime-compatible JSON handling1082- Proxy fixes1083- Path hack fixes1084- Case-Insensitive Content-Encoding headers1085- Support for CJK parameters in form posts108610870.14.1 (2012-10-01)1088-------------------10891090- Python 3.3 Compatibility1091- Simply default accept-encoding1092- Bugfixes109310940.14.0 (2012-09-02)1095-------------------10961097- No more iter\_content errors if already downloaded.109810990.13.9 (2012-08-25)1100-------------------11011102- Fix for OAuth + POSTs1103- Remove exception eating from dispatch\_hook1104- General bugfixes110511060.13.8 (2012-08-21)1107-------------------11081109- Incredible Link header support :)111011110.13.7 (2012-08-19)1112-------------------11131114- Support for (key, value) lists everywhere.1115- Digest Authentication improvements.1116- Ensure proxy exclusions work properly.1117- Clearer UnicodeError exceptions.1118- Automatic casting of URLs to strings (fURL and such)1119- Bugfixes.112011210.13.6 (2012-08-06)1122-------------------11231124- Long awaited fix for hanging connections!112511260.13.5 (2012-07-27)1127-------------------11281129- Packaging fix113011310.13.4 (2012-07-27)1132-------------------11331134- GSSAPI/Kerberos authentication!1135- App Engine 2.7 Fixes!1136- Fix leaking connections (from urllib3 update)1137- OAuthlib path hack fix1138- OAuthlib URL parameters fix.113911400.13.3 (2012-07-12)1141-------------------11421143- Use simplejson if available.1144- Do not hide SSLErrors behind Timeouts.1145- Fixed param handling with urls containing fragments.1146- Significantly improved information in User Agent.1147- client certificates are ignored when verify=False114811490.13.2 (2012-06-28)1150-------------------11511152- Zero dependencies (once again)!1153- New: Response.reason1154- Sign querystring parameters in OAuth 1.01155- Client certificates no longer ignored when verify=False1156- Add openSUSE certificate support115711580.13.1 (2012-06-07)1159-------------------11601161- Allow passing a file or file-like object as data.1162- Allow hooks to return responses that indicate errors.1163- Fix Response.text and Response.json for body-less responses.116411650.13.0 (2012-05-29)1166-------------------11671168- Removal of Requests.async in favor of1169 [grequests](https://github.com/kennethreitz/grequests)1170- Allow disabling of cookie persistence.1171- New implementation of safe\_mode1172- cookies.get now supports default argument1173- Session cookies not saved when Session.request is called with1174 return\_response=False1175- Env: no\_proxy support.1176- RequestsCookieJar improvements.1177- Various bug fixes.117811790.12.1 (2012-05-08)1180-------------------11811182- New `Response.json` property.1183- Ability to add string file uploads.1184- Fix out-of-range issue with iter\_lines.1185- Fix iter\_content default size.1186- Fix POST redirects containing files.118711880.12.0 (2012-05-02)1189-------------------11901191- EXPERIMENTAL OAUTH SUPPORT!1192- Proper CookieJar-backed cookies interface with awesome dict-like1193 interface.1194- Speed fix for non-iterated content chunks.1195- Move `pre_request` to a more usable place.1196- New `pre_send` hook.1197- Lazily encode data, params, files.1198- Load system Certificate Bundle if `certify` isn't available.1199- Cleanups, fixes.120012010.11.2 (2012-04-22)1202-------------------12031204- Attempt to use the OS's certificate bundle if `certifi` isn't1205 available.1206- Infinite digest auth redirect fix.1207- Multi-part file upload improvements.1208- Fix decoding of invalid %encodings in URLs.1209- If there is no content in a response don't throw an error the second1210 time that content is attempted to be read.1211- Upload data on redirects.121212130.11.1 (2012-03-30)1214-------------------12151216- POST redirects now break RFC to do what browsers do: Follow up with1217 a GET.1218- New `strict_mode` configuration to disable new redirect behavior.121912200.11.0 (2012-03-14)1221-------------------12221223- Private SSL Certificate support1224- Remove select.poll from Gevent monkeypatching1225- Remove redundant generator for chunked transfer encoding1226- Fix: Response.ok raises Timeout Exception in safe\_mode122712280.10.8 (2012-03-09)1229-------------------12301231- Generate chunked ValueError fix1232- Proxy configuration by environment variables1233- Simplification of iter\_lines.1234- New trust\_env configuration for disabling system/environment hints.1235- Suppress cookie errors.123612370.10.7 (2012-03-07)1238-------------------12391240- encode\_uri = False124112420.10.6 (2012-02-25)1243-------------------12441245- Allow '=' in cookies.124612470.10.5 (2012-02-25)1248-------------------12491250- Response body with 0 content-length fix.1251- New async.imap.1252- Don't fail on netrc.125312540.10.4 (2012-02-20)1255-------------------12561257- Honor netrc.125812590.10.3 (2012-02-20)1260-------------------12611262- HEAD requests don't follow redirects anymore.1263- raise\_for\_status() doesn't raise for 3xx anymore.1264- Make Session objects picklable.1265- ValueError for invalid schema URLs.126612670.10.2 (2012-01-15)1268-------------------12691270- Vastly improved URL quoting.1271- Additional allowed cookie key values.1272- Attempted fix for "Too many open files" Error1273- Replace unicode errors on first pass, no need for second pass.1274- Append '/' to bare-domain urls before query insertion.1275- Exceptions now inherit from RuntimeError.1276- Binary uploads + auth fix.1277- Bugfixes.127812790.10.1 (2012-01-23)1280-------------------12811282- PYTHON 3 SUPPORT!1283- Dropped 2.5 Support. (*Backwards Incompatible*)128412850.10.0 (2012-01-21)1286-------------------12871288- `Response.content` is now bytes-only. (*Backwards Incompatible*)1289- New `Response.text` is unicode-only.1290- If no `Response.encoding` is specified and `chardet` is available,1291 `Response.text` will guess an encoding.1292- Default to ISO-8859-1 (Western) encoding for "text" subtypes.1293- Removal of decode\_unicode. (*Backwards Incompatible*)1294- New multiple-hooks system.1295- New `Response.register_hook` for registering hooks within the1296 pipeline.1297- `Response.url` is now Unicode.129812990.9.3 (2012-01-18)1300------------------13011302- SSL verify=False bugfix (apparent on windows machines).130313040.9.2 (2012-01-18)1305------------------13061307- Asynchronous async.send method.1308- Support for proper chunk streams with boundaries.1309- session argument for Session classes.1310- Print entire hook tracebacks, not just exception instance.1311- Fix response.iter\_lines from pending next line.1312- Fix but in HTTP-digest auth w/ URI having query strings.1313- Fix in Event Hooks section.1314- Urllib3 update.131513160.9.1 (2012-01-06)1317------------------13181319- danger\_mode for automatic Response.raise\_for\_status()1320- Response.iter\_lines refactor132113220.9.0 (2011-12-28)1323------------------13241325- verify ssl is default.132613270.8.9 (2011-12-28)1328------------------13291330- Packaging fix.133113320.8.8 (2011-12-28)1333------------------13341335- SSL CERT VERIFICATION!1336- Release of Cerifi: Mozilla's cert list.1337- New 'verify' argument for SSL requests.1338- Urllib3 update.133913400.8.7 (2011-12-24)1341------------------13421343- iter\_lines last-line truncation fix1344- Force safe\_mode for async requests1345- Handle safe\_mode exceptions more consistently1346- Fix iteration on null responses in safe\_mode134713480.8.6 (2011-12-18)1349------------------13501351- Socket timeout fixes.1352- Proxy Authorization support.135313540.8.5 (2011-12-14)1355------------------13561357- Response.iter\_lines!135813590.8.4 (2011-12-11)1360------------------13611362- Prefetch bugfix.1363- Added license to installed version.136413650.8.3 (2011-11-27)1366------------------13671368- Converted auth system to use simpler callable objects.1369- New session parameter to API methods.1370- Display full URL while logging.137113720.8.2 (2011-11-19)1373------------------13741375- New Unicode decoding system, based on over-ridable1376 Response.encoding.1377- Proper URL slash-quote handling.1378- Cookies with `[`, `]`, and `_` allowed.137913800.8.1 (2011-11-15)1381------------------13821383- URL Request path fix1384- Proxy fix.1385- Timeouts fix.138613870.8.0 (2011-11-13)1388------------------13891390- Keep-alive support!1391- Complete removal of Urllib21392- Complete removal of Poster1393- Complete removal of CookieJars1394- New ConnectionError raising1395- Safe\_mode for error catching1396- prefetch parameter for request methods1397- OPTION method1398- Async pool size throttling1399- File uploads send real names1400- Vendored in urllib3140114020.7.6 (2011-11-07)1403------------------14041405- Digest authentication bugfix (attach query data to path)140614070.7.5 (2011-11-04)1408------------------14091410- Response.content = None if there was an invalid response.1411- Redirection auth handling.141214130.7.4 (2011-10-26)1414------------------14151416- Session Hooks fix.141714180.7.3 (2011-10-23)1419------------------14201421- Digest Auth fix.142214230.7.2 (2011-10-23)1424------------------14251426- PATCH Fix.142714280.7.1 (2011-10-23)1429------------------14301431- Move away from urllib2 authentication handling.1432- Fully Remove AuthManager, AuthObject, &c.1433- New tuple-based auth system with handler callbacks.143414350.7.0 (2011-10-22)1436------------------14371438- Sessions are now the primary interface.1439- Deprecated InvalidMethodException.1440- PATCH fix.1441- New config system (no more global settings).144214430.6.6 (2011-10-19)1444------------------14451446- Session parameter bugfix (params merging).144714480.6.5 (2011-10-18)1449------------------14501451- Offline (fast) test suite.1452- Session dictionary argument merging.145314540.6.4 (2011-10-13)1455------------------14561457- Automatic decoding of unicode, based on HTTP Headers.1458- New `decode_unicode` setting.1459- Removal of `r.read/close` methods.1460- New `r.faw` interface for advanced response usage.\*1461- Automatic expansion of parameterized headers.146214630.6.3 (2011-10-13)1464------------------14651466- Beautiful `requests.async` module, for making async requests w/1467 gevent.146814690.6.2 (2011-10-09)1470------------------14711472- GET/HEAD obeys allow\_redirects=False.147314740.6.1 (2011-08-20)1475------------------14761477- Enhanced status codes experience `\o/`1478- Set a maximum number of redirects (`settings.max_redirects`)1479- Full Unicode URL support1480- Support for protocol-less redirects.1481- Allow for arbitrary request types.1482- Bugfixes148314840.6.0 (2011-08-17)1485------------------14861487- New callback hook system1488- New persistent sessions object and context manager1489- Transparent Dict-cookie handling1490- Status code reference object1491- Removed Response.cached1492- Added Response.request1493- All args are kwargs1494- Relative redirect support1495- HTTPError handling improvements1496- Improved https testing1497- Bugfixes149814990.5.1 (2011-07-23)1500------------------15011502- International Domain Name Support!1503- Access headers without fetching entire body (`read()`)1504- Use lists as dicts for parameters1505- Add Forced Basic Authentication1506- Forced Basic is default authentication type1507- `python-requests.org` default User-Agent header1508- CaseInsensitiveDict lower-case caching1509- Response.history bugfix151015110.5.0 (2011-06-21)1512------------------15131514- PATCH Support1515- Support for Proxies1516- HTTPBin Test Suite1517- Redirect Fixes1518- settings.verbose stream writing1519- Querystrings for all methods1520- URLErrors (Connection Refused, Timeout, Invalid URLs) are treated as1521 explicitly raised1522 `r.requests.get('hwe://blah'); r.raise_for_status()`152315240.4.1 (2011-05-22)1525------------------15261527- Improved Redirection Handling1528- New 'allow\_redirects' param for following non-GET/HEAD Redirects1529- Settings module refactoring153015310.4.0 (2011-05-15)1532------------------15331534- Response.history: list of redirected responses1535- Case-Insensitive Header Dictionaries!1536- Unicode URLs153715380.3.4 (2011-05-14)1539------------------15401541- Urllib2 HTTPAuthentication Recursion fix (Basic/Digest)1542- Internal Refactor1543- Bytes data upload Bugfix154415450.3.3 (2011-05-12)1546------------------15471548- Request timeouts1549- Unicode url-encoded data1550- Settings context manager and module155115520.3.2 (2011-04-15)1553------------------15541555- Automatic Decompression of GZip Encoded Content1556- AutoAuth Support for Tupled HTTP Auth155715580.3.1 (2011-04-01)1559------------------15601561- Cookie Changes1562- Response.read()1563- Poster fix156415650.3.0 (2011-02-25)1566------------------15671568- Automatic Authentication API Change1569- Smarter Query URL Parameterization1570- Allow file uploads and POST data together1571- 15721573 New Authentication Manager System15741575 : - Simpler Basic HTTP System1576 - Supports all build-in urllib2 Auths1577 - Allows for custom Auth Handlers157815790.2.4 (2011-02-19)1580------------------15811582- Python 2.5 Support1583- PyPy-c v1.4 Support1584- Auto-Authentication tests1585- Improved Request object constructor158615870.2.3 (2011-02-15)1588------------------15891590- 15911592 New HTTPHandling Methods15931594 : - Response.\_\_nonzero\_\_ (false if bad HTTP Status)1595 - Response.ok (True if expected HTTP Status)1596 - Response.error (Logged HTTPError if bad HTTP Status)1597 - Response.raise\_for\_status() (Raises stored HTTPError)159815990.2.2 (2011-02-14)1600------------------16011602- Still handles request in the event of an HTTPError. (Issue \#2)1603- Eventlet and Gevent Monkeypatch support.1604- Cookie Support (Issue \#1)160516060.2.1 (2011-02-14)1607------------------16081609- Added file attribute to POST and PUT requests for multipart-encode1610 file uploads.1611- Added Request.url attribute for context and redirects161216130.2.0 (2011-02-14)1614------------------16151616- Birth!161716180.0.1 (2011-02-13)1619------------------16201621- Frustration1622- Conception1623