scmutil: display the optional hint when handling StorageError in catchall()
Other than CensoredNodeError (which is also a StorageError), it looks like all
exceptions with a hint display them. I'm not sure that it makes sense to have a
hint for censored nodes, so I'm not bothering with that.
It looks like nobody is using this yet, as the tests don't change.
--- a/mercurial/scmutil.py Thu Nov 15 14:57:26 2018 +0100
+++ b/mercurial/scmutil.py Thu Nov 15 17:50:14 2018 -0500
@@ -212,6 +212,8 @@
ui.error(_("abort: file censored %s!\n") % inst)
except error.StorageError as inst:
ui.error(_("abort: %s!\n") % inst)
+ if inst.hint:
+ ui.error(_("(%s)\n") % inst.hint)
except error.InterventionRequired as inst:
ui.error("%s\n" % inst)
if inst.hint: