You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Now, if users access an invalid repository (non-existing, renamed, etc), they would see:
$ git fetch
Gitea: Internal Server Error
Gitea: Internal Server Error
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
The Internal Server Error is quite misleading and there is a error level message in Gitea log:
...ters/private/serv.go:114:ServCommand() [E] Unable to get repository owner: org-name/repo-name Error: user does not exist [uid: 0, name: org-name, keyid: 0]
Since such case is not an serious error, users should not see the Internal Server Error or the error level log messages.
The text was updated successfully, but these errors were encountered:
Gitea serv will currently return an 500 if we try to pull from a repository where
the owner does not exist.
This PR checks for the UserNotExist Error when checking for the user and will
return a NotFound error instead.
Fixgo-gitea#18225
Signed-off-by: Andrew Thornton <art27@cantab.net>
* Return nicer error if trying to pull from non-existent user
Gitea serv will currently return an 500 if we try to pull from a repository where
the owner does not exist.
This PR checks for the UserNotExist Error when checking for the user and will
return a NotFound error instead.
Fix#18225
Chianina
pushed a commit
to Chianina/gitea
that referenced
this issue
Mar 28, 2022
…#18288)
* Return nicer error if trying to pull from non-existent user
Gitea serv will currently return an 500 if we try to pull from a repository where
the owner does not exist.
This PR checks for the UserNotExist Error when checking for the user and will
return a NotFound error instead.
Fixgo-gitea#18225
Now, if users access an invalid repository (non-existing, renamed, etc), they would see:
The
Internal Server Error
is quite misleading and there is a error level message in Gitea log:Since such case is not an serious error, users should not see the
Internal Server Error
or the error level log messages.The text was updated successfully, but these errors were encountered: