errors

package
v5.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 19, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (

	// ErrScorecardInternal indicates a runtime error in Scorecard code.
	ErrScorecardInternal = errors.New("internal error")
	// ErrRepoUnreachable indicates Scorecard is unable to establish connection with the repository.
	ErrRepoUnreachable = errors.New("repo unreachable")
	// ErrUnsupportedHost indicates the repo's host is unsupported.
	ErrUnsupportedHost = errors.New("unsupported host")
	// ErrInvalidURL indicates the repo's full URL was not passed.
	ErrInvalidURL = errors.New("invalid repo flag")
	// ErrShellParsing indicates there was an error when parsing shell code.
	ErrShellParsing = errors.New("error parsing shell code")
	// ErrJobOSParsing indicates there was an error when detecting a job's operating system.
	ErrJobOSParsing = errors.New("error parsing job operating system")
	// ErrUnsupportedCheck indicates check cannot be run for given request.
	ErrUnsupportedCheck = errors.New("check is not supported for this request")
	// ErrCheckRuntime indicates an individual check had a runtime error.
	ErrCheckRuntime = errors.New("check runtime error")
)

Functions

func CreateInternal

func CreateInternal(e error, msg string) error

CreateInternal creates internal error, not using any of the errors listed in public.go.

func GetName

func GetName(err error) string

GetName returns the name of the error.

func WithMessage

func WithMessage(e error, msg string) error

WithMessage wraps any of the errors listed above. For examples, see errors/errors.md.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL