Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewWarnError ¶
func WithPrefix ¶
WithPrefix annotates an error with a prefix.
Types ¶
type NopHandler ¶
type NopHandler struct{}
NopHandler ignores all errors. Useful for testing.
func NewNopHandler ¶
func NewNopHandler() NopHandler
func (NopHandler) Handle ¶
func (h NopHandler) Handle(err error)
func (NopHandler) HandleContext ¶
func (h NopHandler) HandleContext(ctx context.Context, err error)
type SlogHandler ¶
SlogHandler is a Handler that logs errors using slog.
func NewSlogHandler ¶
func NewSlogHandler(logger *slog.Logger) SlogHandler
func (SlogHandler) Handle ¶
func (h SlogHandler) Handle(err error)
func (SlogHandler) HandleContext ¶
func (h SlogHandler) HandleContext(ctx context.Context, err error)
Click to show internal directories.
Click to hide internal directories.