Improve the error message for fork failures
Problem
Originally reported: https://gitlab.com/gitlab-com/dev-sub-department/section-dev-request-for-help/-/issues/8
POST /api/v4/projects/<id>/fork
returns 409 Conflict
response with error message: Unable to save project. Error: Invalid request
The error message is very obscure and needs to be improved.
Root cause
The root cause was a misconfiguration of gitlab_rails['object_store']
. "uploads" => { enabled: false }
was missing and we used the default value true
for that. I suspect that we tried to send an object to object store, but the store was returning an error.
Proposal
- Improve error message by adding extra details (like exception class, possibly the backtrace)
- Try to reproduce the misconfiguration error and find a better way to report this problem.