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

Fix - Internal Server Error 500 for ValidationError #3027

Merged
merged 1 commit into from
Jul 29, 2024

Conversation

sasirven
Copy link
Contributor

This is a fix to prevent an Internal Server Error 500 when using PATCH or PUT on the API and a schema raises a ValidationError.

  • Change the middleware in responses.py for ValidationError to raise an HTTPUnprocessableEntity instead of a JsonHttpBadRequest.

- Change the middleware in responses.py for ValidationError
to raise an HTTPUnprocessableEntity instead of a JsonHttpBadRequest
@elegantmoose
Copy link
Contributor

TY @sasirven

@elegantmoose elegantmoose merged commit fc432b6 into mitre:master Jul 29, 2024
1 of 6 checks passed
@sasirven sasirven deleted the fix/validation-error branch October 15, 2024 09:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants