Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Raise HTTPError in case of HTTP 5XX responses. #441

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Commits on Apr 14, 2021

  1. Raise HTTPError in case of HTTP 5XX responses.

    It is misleading to raise a MissingTokenError when the server has
    returned an HTTP server error.
    
    Instead, raise requests.exceptions.HTTPError if the server has returned
    an HTTP 5XX server error.
    
    Prior PR conversation in PR requests#217 indicates that the maintainers do not
    want to raise on 4XX errors due to certain providers using those
    responses to send data. So we need a custom handler with a slight
    variation on the built-in requests.models.Response.raise_for_status().
    ab committed Apr 14, 2021
    Configuration menu
    Copy the full SHA
    eea0f5b View commit details
    Browse the repository at this point in the history

Commits on Apr 19, 2021

  1. Fix tests.

    ab committed Apr 19, 2021
    Configuration menu
    Copy the full SHA
    bb90460 View commit details
    Browse the repository at this point in the history
  2. Add tests of 5xx error handling.

    ab committed Apr 19, 2021
    Configuration menu
    Copy the full SHA
    ba0e5d2 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    1e0f279 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    073e46a View commit details
    Browse the repository at this point in the history
  5. Appease black.

    ab committed Apr 19, 2021
    Configuration menu
    Copy the full SHA
    a560d84 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    fa78265 View commit details
    Browse the repository at this point in the history