Skip to content
Myr

Document header ordering. (#3295)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Cory Benfield · committed by Ian Cordasco · parent 8813787 · Browse files · 1 file+8 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+8 added−1 removed

  • other:+8 added−1 removed

1 file+8 added−1 removed

modified:docs/user/advanced.rst+8 added-1 removed
206 unmodified lines
207You can pass ``verify`` the path to a CA_BUNDLE file or directory with certificates of trusted CAs::208209 >>> requests.get('https://github.com', verify='/path/to/certfile')210211.. note:: If ``verify`` is set to a path to a directory, the directory must have been processed using 211.. note:: If ``verify`` is set to a path to a directory, the directory must have been processed using212 the c_rehash utility supplied with OpenSSL.213214This list of trusted CAs can also be specified through the ``REQUESTS_CA_BUNDLE`` environment variable.215
682 unmodified lines
898899.. _`grequests`: https://github.com/kennethreitz/grequests900.. _`requests-futures`: https://github.com/ross/requests-futures901902Header Ordering903---------------904905In unusual circumstances you may want to provide headers in an ordered manner. If you pass an ``OrderedDict`` to the ``headers`` keyword argument, that will provide the headers with an ordering. *However*, the ordering of the default headers used by requests will be preferred, which means that if you override default headers in the ``headers`` keyword argument, they may appear out of order compared to other headers in that keyword argument.906907If this is problematic, users should consider setting the default headers on a :class:`Session <requests.Session>` object, by setting :data:`Session <requests.Session.headers>` to a custom ``OrderedDict``. That ordering will always be preferred.908909.. _timeouts:910911Timeouts912--------
35 unmodified lines