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

feat(pq): use 4xx status code on PQ errors #4887

Merged
merged 1 commit into from
Apr 4, 2024

Commits on Mar 29, 2024

  1. feat(pq): use 4xx status code on PQ errors

    Previously, sending a request that failed for a PQ-related reason would
    return a 200 status code. Now, various PQ-related errors lead to non-200
    status codes:
    
    - Sending a PQ ID that is unknown yields 404 Not Found
    - Sending freeform GraphQL when no freeform GraphQL is allowed yields
      400 Bad Request
    - Sending both a PQ ID and freeform GraphQL in the same request (if the
      APQ feature is not also enabled) yields 400 Bad Request
    - Sending freeform GraphQL that is not in the safelist when the safelist
      is enabled yields 403 Forbidden
    - A particular internal error that shouldn't happen yields 500 Internal
      Server Error
    glasser committed Mar 29, 2024
    Configuration menu
    Copy the full SHA
    295d760 View commit details
    Browse the repository at this point in the history