Tags::CreateService: add a handler for NoRepository exception
What does this MR do and why?
Contributes to #525296 (closed)
Problem
When provided tag information is incorrect, Gitaly returns a "Could not update refs/tags/%s. Please refresh and try again." error.
This error is not handled by Rails and causes a 500 error.
Solution
Add a handler for this exception and return a user-friendly error message instead.
References
Screenshots or screen recordings
Before | After |
---|---|
![]() |
![]() |
How to set up and validate locally
- Visit create new tag page
- Try to create a tag with name (includes special symbols):
test
- You should see a human-friendly error
MR acceptance checklist
Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Edited by Vasilii Iakliushin