Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: psf/requests
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v2.22.0
Choose a base ref
...
head repository: psf/requests
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v2.23.0
Choose a head ref

Commits on Dec 29, 2018

  1. Remove internal use of unnecessary compat shim for OrderedDict

    The shim is the same on both Python 2 & 3. It is always
    collections.OrderedDict. Avoid the indirection and import from Python
    stdlib instead.
    
    Keep requests.compat.OrderedDict for backwards compatibility. Some
    packages import this.
    jdufresne committed Dec 29, 2018
    Copy the full SHA
    2aab9a9 View commit details

Commits on Feb 9, 2019

  1. add utf8 with bom to test

    Eduardo Rodrigues committed Feb 9, 2019
    Copy the full SHA
    f507a3e View commit details
  2. add failing tests for bom

    Eduardo Rodrigues committed Feb 9, 2019
    Copy the full SHA
    9e27326 View commit details
  3. fix response with utf8 bom

    Eduardo Rodrigues committed Feb 9, 2019
    Copy the full SHA
    19cff44 View commit details

Commits on Feb 12, 2019

  1. Fix double image request

    Use official framework for the "custom" ad design integration.
    Sayz Lim committed Feb 12, 2019
    Copy the full SHA
    5add08f View commit details

Commits on Feb 15, 2019

  1. Add trusted domains

    jaketreacher committed Feb 15, 2019
    Copy the full SHA
    fbe48fb View commit details

Commits on Feb 17, 2019

  1. [fix] fix failing doctests in requests/*

    [add] add --doctest-modules in pytest.ini file as addopts
    [add] add myself to AUTHORS
    aless10 committed Feb 17, 2019
    Copy the full SHA
    177f4dd View commit details
  2. Copy the full SHA
    fd926e7 View commit details

Commits on Feb 22, 2019

  1. Add link to user-agent documentation

    So the user has a pointer to the documentation about the searched topic.
    sblondon authored Feb 22, 2019
    Copy the full SHA
    2482114 View commit details

Commits on Feb 23, 2019

  1. Copy the full SHA
    7d7d9eb View commit details

Commits on Mar 10, 2019

  1. Copy the full SHA
    a7969c5 View commit details

Commits on Mar 26, 2019

  1. Copy the full SHA
    aa21dbe View commit details

Commits on Apr 7, 2019

  1. Copy the full SHA
    c19c394 View commit details
  2. [remove] remove invalid field in docete

    Remove 'Connection': 'close' field in 'headers'
    aless10 authored Apr 7, 2019
    Copy the full SHA
    8b773a4 View commit details

Commits on Apr 23, 2019

  1. Copy the full SHA
    663aa11 View commit details

Commits on Apr 30, 2019

  1. Possible fix for #4945?

    Could the missing colon on line 612 be the reason for the missing reference in the docs as described in issue #4945?
    myrheimb authored Apr 30, 2019
    Copy the full SHA
    a310b5a View commit details

Commits on May 13, 2019

  1. #4965 fix-draw: Accessing response.content twice removes forgets read…

    … error.
    Белавин Денис committed May 13, 2019
    Copy the full SHA
    d91fe00 View commit details

Commits on May 14, 2019

  1. #4965 fix: Accessing response.content twice removes forgets read error.

    Белавин Денис committed May 14, 2019
    Copy the full SHA
    bd10047 View commit details
  2. Merge pull request #1 from kennethreitz/master

    Updating my fork with the original
    zurbrugc authored May 14, 2019
    Copy the full SHA
    4803716 View commit details
  3. Linked how to make a pull requests in README

    This makes it easier for users new to GitHub to learn how to make a pull request.
    zurbrugc authored May 14, 2019
    Copy the full SHA
    44256ff View commit details

Commits on May 16, 2019

  1. Copy the full SHA
    8e26bfd View commit details
  2. Copy the full SHA
    86760da View commit details
  3. Merge pull request #5088 from zurbrugc/master

    Linked a GitHub tutorial regarding pull requests in README
    frostming authored May 16, 2019
    Copy the full SHA
    a79a633 View commit details
  4. Copy the full SHA
    d36f391 View commit details
  5. Simplify config

    hugovk authored May 16, 2019
    Copy the full SHA
    be295ba View commit details

Commits on May 19, 2019

  1. Copy the full SHA
    4a59cd0 View commit details
  2. Copy the full SHA
    67a0e90 View commit details
  3. Copy the full SHA
    2e63347 View commit details
  4. Copy the full SHA
    96ff7ca View commit details
  5. [add] add NORMALIZE_WHITESPACE and ELLIPSIS to pytest.ini and remove …

    …them from requests/__init__.py
    aless10 committed May 19, 2019
    Copy the full SHA
    6d2a507 View commit details

Commits on May 20, 2019

  1. Copy the full SHA
    d88240b View commit details
  2. Copy the full SHA
    9c3c755 View commit details
  3. Merge pull request #5099 from petar-iv/password-no-print

    Print the type of the password instead of the password itself
    bisguzar authored May 20, 2019
    Copy the full SHA
    6f81e78 View commit details
  4. Copy the full SHA
    0becdca View commit details

Commits on May 23, 2019

  1. Copy the full SHA
    dc75b3c View commit details

Commits on May 24, 2019

  1. Copy the full SHA
    d889b98 View commit details

Commits on May 29, 2019

  1. Update sessions.py

    -Made removing a key-value pair more modular
    -Remove unneeeded return statement
    alanyee authored May 29, 2019
    Copy the full SHA
    47cb8ba View commit details

Commits on Jun 3, 2019

  1. Copy the full SHA
    2e4329d View commit details
  2. Merge pull request #5108 from atombrella/python34

    Removed py34 from tox.ini.
    nateprewitt authored Jun 3, 2019
    Copy the full SHA
    4983a9b View commit details

Commits on Jun 13, 2019

  1. Copy the full SHA
    6296df9 View commit details
  2. Copy the full SHA
    27b24f9 View commit details

Commits on Jun 24, 2019

  1. Update sessions.py

    Use `.format()` over `%` given PEP 3101
    alanyee authored Jun 24, 2019
    Copy the full SHA
    45c2e67 View commit details

Commits on Jul 1, 2019

  1. Document that request.head defaults allow_redirects to False

    Related: kennethreitz/requests#4274
    Unit03 committed Jul 1, 2019
    Copy the full SHA
    c8d8b4b View commit details

Commits on Jul 2, 2019

  1. Copy the full SHA
    2da7fe0 View commit details

Commits on Jul 12, 2019

  1. Merge pull request #5127 from Unit03/head-allow-redirects-docstring

    Document that `request.head` defaults `allow_redirects` to `False`
    kobayashi authored Jul 12, 2019
    Copy the full SHA
    0b6c110 View commit details

Commits on Jul 19, 2019

  1. Fix typos

    minho42 committed Jul 19, 2019
    Copy the full SHA
    5f576ad View commit details

Commits on Jul 20, 2019

  1. Copy the full SHA
    fb7efcf View commit details
  2. Copy the full SHA
    50daf9c View commit details
  3. Copy the full SHA
    ebd3e36 View commit details
  4. Fix GitHub profile link

    dullbananas committed Jul 20, 2019
    1
    Copy the full SHA
    f9ac75c View commit details
Showing with 617 additions and 788 deletions.
  1. 0 { → .github}/CODE_OF_CONDUCT.md
  2. +2 −2 { → .github}/CONTRIBUTING.md
  3. +1 −0 .github/FUNDING.yml
  4. +93 −0 .github/SECURITY.md
  5. +6 −0 .gitignore
  6. +7 −16 .travis.yml
  7. +4 −4 AUTHORS.rst
  8. +27 −11 HISTORY.md
  9. +1 −1 LICENSE
  10. +9 −8 Pipfile
  11. +117 −116 Pipfile.lock
  12. +88 −69 README.md
  13. +1 −0 docs/.nojekyll
  14. +20 −25 docs/_static/custom.css
  15. +0 −131 docs/_static/native.js
  16. BIN docs/_static/requests-logo-small.jpg
  17. BIN docs/_static/requests-logo-small.png
  18. BIN docs/_static/requests-sidebar.jpg
  19. BIN docs/_static/requests-sidebar.png
  20. +42 −35 docs/_templates/hacks.html
  21. +36 −88 docs/_templates/sidebarintro.html
  22. +36 −55 docs/_templates/sidebarlogo.html
  23. +14 −9 docs/community/faq.rst
  24. +1 −1 docs/community/recommended.rst
  25. +0 −96 docs/community/sponsors.rst
  26. +1 −1 docs/community/support.rst
  27. +1 −1 docs/community/updates.rst
  28. +9 −2 docs/dev/contributing.rst
  29. +2 −2 docs/dev/todo.rst
  30. +7 −45 docs/index.rst
  31. +9 −9 docs/user/advanced.rst
  32. +5 −5 docs/user/install.rst
  33. +1 −0 ext/LICENSE
  34. BIN ext/flower-of-life.jpg
  35. BIN ext/kr-compressed.png
  36. BIN ext/kr.png
  37. BIN ext/psf-compressed.png
  38. BIN ext/psf.png
  39. BIN ext/requests-logo-compressed.png
  40. BIN ext/requests-logo.png
  41. BIN ext/ss-compressed.png
  42. BIN ext/ss.png
  43. +2 −1 pytest.ini
  44. +6 −6 requests/__init__.py
  45. +4 −4 requests/__version__.py
  46. +5 −2 requests/api.py
  47. +2 −2 requests/auth.py
  48. +2 −0 requests/compat.py
  49. +4 −3 requests/models.py
  50. +10 −13 requests/sessions.py
  51. +9 −6 requests/status_codes.py
  52. +3 −1 requests/structures.py
  53. +8 −3 requests/utils.py
  54. +9 −4 setup.py
  55. +2 −2 tests/test_lowlevel.py
  56. +6 −6 tests/test_requests.py
  57. +3 −2 tests/test_utils.py
  58. +1 −0 tests/testserver/server.py
  59. +1 −1 tox.ini
File renamed without changes.
4 changes: 2 additions & 2 deletions CONTRIBUTING.md → .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -3,8 +3,8 @@
Before opening any issues or proposing any pull requests, please do the
following:

1. Read our [Contributor's Guide](http://docs.python-requests.org/en/latest/dev/contributing/).
2. Understand our [development philosophy](http://docs.python-requests.org/en/latest/dev/philosophy/).
1. Read our [Contributor's Guide](https://requests.readthedocs.io/en/latest/dev/contributing/).
2. Understand our [development philosophy](https://requests.readthedocs.io/en/latest/dev/philosophy/).

To get the greatest chance of helpful responses, please also observe the
following additional notes.
1 change: 1 addition & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
custom: ['https://www.python.org/psf/forms/sponsor-application/']
93 changes: 93 additions & 0 deletions .github/SECURITY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
# Vulnerability Disclosure

![](https://farm5.staticflickr.com/4211/34709353644_b041e9e1c2_k_d.jpg)

If you think you have found a potential security vulnerability in
requests, please email
`sigmavirus24 <mailto:graffatcolmingov@gmail.com>`\_ and
`Nate <mailto:nate.prewitt@gmail.com>`\_ directly. **Do not file a
public issue.**

Our PGP Key fingerprints are:

- 0161 BB7E B208 B5E0 4FDC 9F81 D9DA 0A04 9113 F853 (@sigmavirus24)

- 8722 7E29 AD9C FF5C FAC3 EA6A 44D3 FF97 B80D C864 (@nateprewitt)

If English is not your first language, please try to describe the
problem and its impact to the best of your ability. For greater detail,
please use your native language and we will try our best to translate it
using online services.

Please also include the code you used to find the problem and the
shortest amount of code necessary to reproduce it.

Please do not disclose this to anyone else. We will retrieve a CVE
identifier if necessary and give you full credit under whatever name or
alias you provide. We will only request an identifier when we have a fix
and can publish it in a release.

We will respect your privacy and will only publicize your involvement if
you grant us permission.

## Process

This following information discusses the process the requests project
follows in response to vulnerability disclosures. If you are disclosing
a vulnerability, this section of the documentation lets you know how we
will respond to your disclosure.

### Timeline

When you report an issue, one of the project members will respond to you
within two days *at the outside*. In most cases responses will be
faster, usually within 12 hours. This initial response will at the very
least confirm receipt of the report.

If we were able to rapidly reproduce the issue, the initial response
will also contain confirmation of the issue. If we are not, we will
often ask for more information about the reproduction scenario.

Our goal is to have a fix for any vulnerability released within two
weeks of the initial disclosure. This may potentially involve shipping
an interim release that simply disables function while a more mature fix
can be prepared, but will in the vast majority of cases mean shipping a
complete release as soon as possible.

Throughout the fix process we will keep you up to speed with how the fix
is progressing. Once the fix is prepared, we will notify you that we
believe we have a fix. Often we will ask you to confirm the fix resolves
the problem in your environment, especially if we are not confident of
our reproduction scenario.

At this point, we will prepare for the release. We will obtain a CVE
number if one is required, providing you with full credit for the
discovery. We will also decide on a planned release date, and let you
know when it is. This release date will *always* be on a weekday.

At this point we will reach out to our major downstream packagers to
notify them of an impending security-related patch so they can make
arrangements. In addition, these packagers will be provided with the
intended patch ahead of time, to ensure that they are able to promptly
release their downstream packages. Currently the list of people we
actively contact *ahead of a public release* is:

- Jeremy Cline, Red Hat (@jeremycline)
- Daniele Tricoli, Debian (@eriol)

We will notify these individuals at least a week ahead of our planned
release date to ensure that they have sufficient time to prepare. If you
believe you should be on this list, please let one of the maintainers
know at one of the email addresses at the top of this article.

On release day, we will push the patch to our public repository, along
with an updated changelog that describes the issue and credits you. We
will then issue a PyPI release containing the patch.

At this point, we will publicise the release. This will involve mails to
mailing lists, Tweets, and all other communication mechanisms available
to the core team.

We will also explicitly mention which commits contain the fix to make it
easier for other distributors and users to easily patch their own
versions of requests if upgrading is not an option.
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -14,6 +14,12 @@ requests.egg-info/
*.swp
*.egg
env/
.venv/
.eggs/
.tox/
.pytest_cache/
.vscode/
.eggs/

.workon

23 changes: 7 additions & 16 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -3,33 +3,24 @@ language: python
install: "make"
# command to run tests
script:
- |
make test-readme
- make test-readme
- make ci
cache: pip
jobs:
include:
- stage: test
script:
- make test-readme
- make ci
python: '2.7'
- stage: test
script:
- make test-readme
- make ci
python: '3.5'
- stage: test
script:
- make test-readme
- make ci
python: '3.6'
- stage: test
script:
- make test-readme
- make ci
python: '3.7'
dist: xenial
python: '3.7'
- stage: test
python: 'pypy3'
dist: xenial
- stage: test
python: '3.8'
- stage: coverage
python: '3.6'
script: codecov
8 changes: 4 additions & 4 deletions AUTHORS.rst
Original file line number Diff line number Diff line change
@@ -1,16 +1,14 @@
Requests is written and maintained by Kenneth Reitz and
various contributors:
Requests was lovingly created by Kenneth Reitz.

Keepers of the Crystals
```````````````````````

- Kenneth Reitz <me@kennethreitz.org> `@kennethreitz <https://github.com/kennethreitz>`_, Keeper of the Master Crystal.
- Ian Cordasco <graffatcolmingov@gmail.com> `@sigmavirus24 <https://github.com/sigmavirus24>`_.
- Nate Prewitt <nate.prewitt@gmail.com> `@nateprewitt <https://github.com/nateprewitt>`_.

Previous Keepers of Crystals
````````````````````````````

- Kenneth Reitz <me@kennethreitz.org> `@kennethreitz <https://github.com/kennethreitz>`_, reluctant Keeper of the Master Crystal.
- Cory Benfield <cory@lukasa.co.uk> `@lukasa <https://github.com/lukasa>`_


@@ -189,3 +187,5 @@ Patches and Suggestions
- Darren Dormer (`@ddormer <https://github.com/ddormer>`_)
- Rajiv Mayani (`@mayani <https://github.com/mayani>`_)
- Antti Kaihola (`@akaihola <https://github.com/akaihola>`_)
- "Dull Bananas" <dull.bananas0@gmail.com> (`@dullbananas <https://github.com/dullbananas>`_)
- Alessio Izzo (`@aless10 <https://github.com/aless10>`_)
38 changes: 27 additions & 11 deletions HISTORY.md
Original file line number Diff line number Diff line change
@@ -8,6 +8,22 @@ dev

- \[Short description of non-trivial change.\]

2.23.0 (2020-02-19)
-------------------

**Improvements**

- Remove defunct reference to `prefetch` in Session `__attrs__` (#5110)

**Bugfixes**

- Requests no longer outputs password in basic auth usage warning. (#5099)

**Dependencies**

- Pinning for `chardet` and `idna` now uses major version instead of minor.
This hopefully reduces the need for releases everytime a dependency is updated.

2.22.0 (2019-05-15)
-------------------

@@ -549,7 +565,7 @@ Or, even better:

**Bugfixes**

- For file-like objects that are not seeked to the very beginning, we
- For file-like objects that are not sought to the very beginning, we
now send the content length for the number of bytes we will actually
read, rather than the total size of the file, allowing partial file
uploads.
@@ -629,7 +645,7 @@ Or, even better:

This is the first release that follows our new release process. For
more, see [our
documentation](http://docs.python-requests.org/en/latest/community/release-process/).
documentation](https://requests.readthedocs.io/en/latest/community/release-process/).

**Bugfixes**

@@ -793,34 +809,34 @@ documentation](http://docs.python-requests.org/en/latest/community/release-proce
- Unicode URL improvements for Python 2.
- Re-order JSON param for backwards compat.
- Automatically defrag authentication schemes from host/pass URIs.
([\#2249](https://github.com/requests/requests/issues/2249))
([\#2249](https://github.com/psf/requests/issues/2249))

2.4.2 (2014-10-05)
------------------

**Improvements**

- FINALLY! Add json parameter for uploads!
([\#2258](https://github.com/requests/requests/pull/2258))
([\#2258](https://github.com/psf/requests/pull/2258))
- Support for bytestring URLs on Python 3.x
([\#2238](https://github.com/requests/requests/pull/2238))
([\#2238](https://github.com/psf/requests/pull/2238))

**Bugfixes**

- Avoid getting stuck in a loop
([\#2244](https://github.com/requests/requests/pull/2244))
([\#2244](https://github.com/psf/requests/pull/2244))
- Multiple calls to iter\* fail with unhelpful error.
([\#2240](https://github.com/requests/requests/issues/2240),
[\#2241](https://github.com/requests/requests/issues/2241))
([\#2240](https://github.com/psf/requests/issues/2240),
[\#2241](https://github.com/psf/requests/issues/2241))

**Documentation**

- Correct redirection introduction
([\#2245](https://github.com/requests/requests/pull/2245/))
([\#2245](https://github.com/psf/requests/pull/2245/))
- Added example of how to send multiple files in one request.
([\#2227](https://github.com/requests/requests/pull/2227/))
([\#2227](https://github.com/psf/requests/pull/2227/))
- Clarify how to pass a custom set of CAs
([\#2248](https://github.com/requests/requests/pull/2248/))
([\#2248](https://github.com/psf/requests/pull/2248/))

2.4.1 (2014-09-09)
------------------
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright 2018 Kenneth Reitz
Copyright 2019 Kenneth Reitz

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
17 changes: 9 additions & 8 deletions Pipfile
Original file line number Diff line number Diff line change
@@ -4,21 +4,22 @@ verify_ssl = true
name = "pypi"

[dev-packages]
pytest = ">=2.8.0,<=3.10.1"
alabaster = "*"
codecov = "*"
docutils = "*"
detox = "*"
"flake8" = "*"
httpbin = ">=0.7.0"
more-itertools = "<6.0"
pysocks = "*"
pytest = ">=2.8.0,<=3.10.1"
pytest-httpbin = ">=0.0.7,<1.0"
pytest-mock = "*"
pytest-cov = "*"
pytest-xdist = "<=1.25"
alabaster = "*"
readme-renderer = "*"
sphinx = "<=1.5.5"
pysocks = "*"
docutils = "*"
"flake8" = "*"
tox = "*"
detox = "*"
httpbin = ">=0.7.0"

[packages]
"e1839a8" = {path = ".", editable = true, extras = ["socks"]}
"requests" = {path = ".", editable = true, extras = ["socks"]}
Loading