updateref: Improve errors to include breadcrumbs
When we get reports from customers about issues with running hooks it's
always hard to figure out what exactly is happening. Part of the problem
is that the errors we return from the UpdaterWithHooks
aren't properly
wrappend and don't have any breadcrumbs. As a result, it's hard to see
without digging deep what code path has actually caused an error.
Improve the situation by properly wrapping errors. While this changes the error messages, callers shouldn't rely on them anymore anyway and instead only ever access the structured errors, which remain unchanged.