Documentation
¶
Overview ¶
Package unknown is the always-last fallback CompositeError type, shipped as a builtin so that every recorded incident has a typed, catalog-registered representation even when no parser matches.
Index ¶
Constants ¶
const Type composite_error.Type = "unknown_error"
Type is the catalog identifier for the unknown error.
Variables ¶
This section is empty.
Functions ¶
func Build ¶
func Build(in composite_error.ParseInput) composite_error.ParseResult
Build constructs an unknown_error ParseResult from raw input. The pipeline uses this as its safety-net builder when no parser matches.
Lives on the type package (rather than the pipeline package) so that the rules for "what does an unknown error look like" stay alongside the type.
Types ¶
type Error ¶
type Error struct {
// Message is the cleaned outermost error string. Used as the headline.
Message string `json:"message,omitempty"`
// Details is the full (capped) raw error text. Rendered as an "Error
// details" section when it carries information beyond Message — i.e.
// multi-line stderr, wrapped Go error chains, etc.
Details string `json:"details,omitempty"`
// ExitCode of the producing process, when known.
ExitCode *int `json:"exit_code,omitempty"`
}
Error is the typed representation of an unclassified error. All fields are best-effort: even an empty value renders to a usable (if generic) view.
func (*Error) Domain ¶
func (e *Error) Domain() composite_error.Domain
func (*Error) Severity ¶
func (e *Error) Severity() composite_error.Severity
func (*Error) Type ¶
func (e *Error) Type() composite_error.Type