logger

package
v4.90.2 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2026 License: MIT Imports: 8 Imported by: 30 modules, 56 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ErrorField added in v4.69.5

func ErrorField(err error) errorField

func FatalfOnErr added in v4.70.1

func FatalfOnErr(ctx context.Context, err error, msg string, args ...slog.Attr)

func Init added in v4.63.0

func Init(ctx context.Context, config *Config)

Types

type Config

type Config struct {
	Level      string
	TimeKey    string
	LevelKey   string
	MessageKey string
	JSON       bool
}

func Flags

func Flags(flagSet *flag.FlagSet, prefix string, overrides ...flags.Override) *Config

type StackTracer added in v4.70.3

type StackTracer interface {
	StackTrace() string
}

type UnwrapJoin added in v4.70.3

type UnwrapJoin interface {
	Unwrap() []error
}

Jump to

Keyboard shortcuts

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