package debug

import "github.com/docker/cli/cli/debug"

Index

Variables

var OTELErrorHandler otel.ErrorHandler = otel.ErrorHandlerFunc(func(err error) {
	logrus.WithError(err).Debug("otel error")
})

OTELErrorHandler is an error handler for OTEL that uses the CLI debug package to log messages when an error occurs.

The default is to log to the debug level which is only enabled when debugging is enabled.

Functions

func Disable

func Disable()

Disable sets the DEBUG env var to false and makes the logger to log at info level.

func Enable

func Enable()

Enable sets the DEBUG env var to true and makes the logger to log at debug level.

func IsEnabled

func IsEnabled() bool

IsEnabled checks whether the debug flag is set or not.

Source Files

debug.go

Version
v27.2.1+incompatible
Published
Sep 6, 2024
Platform
js/wasm
Imports
3 packages
Last checked
3 hours ago

Tools for package owners.