core: error-exit machine readable output type for errors [GH-2999]