Reword error message when git fails to create pack file
When git
process fails to create the pack object for whatever reason, it outputs the following error message:
That message is a bit scary at least and misleading at most. When the pack-objects hook is enabled, git
triggers another process to create the packfile for it. GitLab leverages this feature to implement pack-objects caching. We do that by using gitaly-hooks
. That hook calls back to Gitaly via an internal channel. When Gitaly rejects such requests, the whole chain fails and user receives such error messages.
Gitaly may have reasons for request rejection. It's not necessary because the repository is corrupted. Thus, this error message may raise unnecessary support tickets from customers. Let gitaly-hook propagate limit error back to c... (!5674 - merged) adds some clarification, but it doesn't make the message go way.
It makes sense to reword that message. It's even better if we can customize it. That message is defined in the git core.