-
Notifications
You must be signed in to change notification settings - Fork 54
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: Change successful schema add status to 200 #1106
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. That said I thought a few of the places where it was StatusBadRequest and now StatusInternalServerError could be one of the other depending on the situation, although it seems to better to err on the side of StatusInternalServerError for perhaps a bit more clarity to the user. "The server errs with this broken request".
Codecov Report
@@ Coverage Diff @@
## develop #1106 +/- ##
===========================================
- Coverage 67.41% 67.39% -0.02%
===========================================
Files 178 178
Lines 16635 16635
===========================================
- Hits 11214 11211 -3
- Misses 4474 4476 +2
- Partials 947 948 +1
|
Benchmark ResultsSummary
✅ See Better Results...
❌ See Worse Results...
✨ See Unchanged Results...
🐋 See Full Results... |
Where I changed it it's because I thought a 500 error was more appropriate but if you think it's not the case in a given situation, let me know :) |
I think it's appropriate. My comment was just that there seems to be a more ideal world in which we classify perfectly between user error and server error but it'd require more work and it's not worth it at this point. |
Relevant issue(s) Resolves #1100 Description This PR changes the returned status code from the http api on a schema add call to be 200 instead of 404. It also changes a few other statuses from 400 to 500 to be more appropriate.
Relevant issue(s) Resolves sourcenetwork#1100 Description This PR changes the returned status code from the http api on a schema add call to be 200 instead of 404. It also changes a few other statuses from 400 to 500 to be more appropriate.
Relevant issue(s)
Resolves #1100
Description
This PR changes the returned status code from the http api on a schema add call to be
200
instead of404
. It also changes a few other statuses from 400 to 500 to be more appropriate.Tasks
How has this been tested?
manual CLI call
Specify the platform(s) on which this was tested: