Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Add HTTP 400 Bad Request as a possible generic error response#1165

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
sliverc merged 1 commit intodjango-json-api:mainfromarttuperala:openapi-400-bad-request
Jul 3, 2023
Merged

Add HTTP 400 Bad Request as a possible generic error response#1165

sliverc merged 1 commit intodjango-json-api:mainfromarttuperala:openapi-400-bad-request
Jul 3, 2023

Conversation

arttuperala
Copy link
Contributor

Description of the Change

Adds400 Bad Request as a possible error response, as JSON:API specification says to use it for requests with badinclude /sort or otherwise illegal query parameters, and advocates using it as an appropriate status code for multiple 4xx errors. DJA's documentation also mentions400 Bad Request multiple times, so it's a bit weird if it's not documented as a possible response.

Discovered during an OpenAPI schema validation run as our generic error responses were not found in the schema.

Checklist

  • PR only contains one change (considered splitting up PR)
  • unit-test added
  • documentation updated
  • CHANGELOG.md updated (only for user relevant changes)
  • author name inAUTHORS

Copy link
Member

@slivercsliverc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Thanks. Indeed, that makes sense. Merging.

@slivercsliverc merged commit39a9c92 intodjango-json-api:mainJul 3, 2023
@arttuperalaarttuperala deleted the openapi-400-bad-request branchJuly 6, 2023 10:26
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@slivercslivercsliverc approved these changes

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

2 participants
@arttuperala@sliverc

[8]ページ先頭

©2009-2025 Movatter.jp