sloglint
sloglint copied to clipboard
Allow slog.Group() when setting no-mixed-args: true or kv-only: true
The slog.Group()
function is the only means to put some grouped data elements between other elements into the log.
A call like
logger.Info("message", "key1", value1, slog.Group("group", "key2", value2, "key3", value3), "key4", value4)
should be allowed, and the arguments to slog.Group()
should be checked for key-value pairs, too.