We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
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
No response
1.23.0+dev-460-ga366af4b7a (or 1.22)
Yes
This works,
curl -X 'GET' \ 'https://demo.gitea.com/api/v1/repos/bartvdbraak/blender/commits?sha=before-big-change&stat=false&verification=false&files=false&page=1' \ -H 'accept: application/json'
but changing the sha= parameter to invalid one (eg. a branch that doesn't exist)
curl -X 'GET' \ 'https://demo.gitea.com/api/v1/repos/bartvdbraak/blender/commits?sha=not-before-big-change&stat=false&verification=false&files=false&page=1' \ -H 'accept: application/json'
results in error 500. Expectation is we get an empty result set with result code of 200 if repository exists but branch/commit id does not.
None
The text was updated successfully, but these errors were encountered:
So, looks like any error in the sources results in error 500. Is this just temporary result at the time until a better one can be found?
204 No Content
is probably also applicable here, if no commits are found.
Sorry, something went wrong.
Return 204 instead of error when commit not exist
0746d8d
Fix go-gitea#31976
404 doesn't seem to match this error condition either since that is returned when repository is not there, not just a branch.
Return 404 instead of error when commit not exist
931de1a
bf7ae04
Successfully merging a pull request may close this issue.
Description
No response
Gitea Version
1.23.0+dev-460-ga366af4b7a (or 1.22)
Can you reproduce the bug on the Gitea demo site?
Yes
Log Gist
No response
Screenshots
No response
Git Version
No response
Operating System
No response
How are you running Gitea?
This works,
but changing the sha= parameter to invalid one (eg. a branch that doesn't exist)
results in error 500. Expectation is we get an empty result set with result code of 200 if repository exists but branch/commit id does not.
Database
None
The text was updated successfully, but these errors were encountered: