logs

package
v1.108.33 Latest Latest
Warning

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

Go to latest
Published: Sep 4, 2026 License: Apache-2.0 Imports: 2 Imported by: ? modules, 0 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

Overview

Package logs writes visor's leveled log lines.

It is log/slog underneath, and the whole package is the signature: a format string and its arguments, always in that order.

That signature is the point. The framework logger this replaced took an interface{} first argument and reached for Sprintf only when arguments followed, so logs.Info("failed: ", err) produced a line ending in %!(EXTRA *errors.errorString=…) rather than the error — a message that lost the one fact it was written to carry, and lost it at runtime, in the log, where nobody was going to be looking. Requiring a format makes that shape a compile-time fact instead.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Error

func Error(format string, v ...any)

func Info

func Info(format string, v ...any)

func Warning

func Warning(format string, v ...any)

Types

This section is empty.

Jump to

Keyboard shortcuts

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