MCPcopy
hub / github.com/slimtoolkit/slim / FailOn

Function FailOn

pkg/util/errutil/errutil.go:30–40  ·  view source on GitHub ↗

FailOn logs the error information (terminates the application)

(err error)

Source from the content-addressed store, hash-verified

28
29// FailOn logs the error information (terminates the application)
30func FailOn(err error) {
31 if err != nil {
32 stackData := debug.Stack()
33 log.WithError(err).WithFields(log.Fields{
34 "version": version.Current(),
35 "stack": string(stackData),
36 }).Fatal("slim: failure")
37
38 showCommunityInfo()
39 }
40}
41
42// WarnOn logs the error information as a warning
43func WarnOn(err error) {

Callers 15

RunFunction · 0.92
RunFunction · 0.92
RunContainerMethod · 0.92
ProcessCollectedDataMethod · 0.92
NewInteractiveAppFunction · 0.92
OnPullCommandFunction · 0.92
OnCopyCommandFunction · 0.92
OnCommandFunction · 0.92
OnCommandFunction · 0.92
OnCommandFunction · 0.92
OnCommandFunction · 0.92
OnCommandFunction · 0.92

Calls 2

CurrentFunction · 0.92
showCommunityInfoFunction · 0.85

Tested by

no test coverage detected