Categorygithub.com/Scalingo/go-utils/errors/v2
modulepackage
2.4.0
Repository: https://github.com/scalingo/go-utils.git
Documentation: pkg.go.dev

# README

Package errors v2.4.0

The package errors contains various utility regarding errors management.

# Functions

As checks if any error of the stack matches the expectedType API machting the standard library but allowing to wrap errors with ErrCtx + errgo or pkg/errors.
No description provided by the author
Is checks if any error of the stack matches the error value expectedError API machting the standard library but allowing to wrap errors with ErrCtx + errgo or pkg/errors.
IsRootCause return true if the cause of the given error is the same type as mytype.
No description provided by the author
No description provided by the author
NewValidationErrors return an empty ValidationErrors struct.
Deprecated: Use `Wrap` or `Wrapf` instead of `Notef`.
RootCause returns the cause of an errors stack, whatever the method they used to be stacked: either errgo.Notef or errors.Wrapf.
RootCtxOrFallback unwrap all wrapped errors from err to get the deepest context from ErrCtx errors.
UnwrapError tries to unwrap `err`.
No description provided by the author
No description provided by the author

# Structs

No description provided by the author
ValidationErrors store each errors associated to every fields of a model.
ValidationErrorsBuilder is used to provide a simple way to create a ValidationErrors struct.