Describe the bug
First-time Zap user here!
Zap doesn't print out any log when using L().
To Reproduce
go mod init test
go get go.uber.org/zap (v1.27.0)
- Create simplest
main.go:
cat << EOF > main.go
package main
import "go.uber.org/zap"
func main() {
zap.L().Debug("DEBUG")
zap.L().Info("INFO")
zap.L().Warn("WARN")
zap.L().Fatal("FATAL")
}
EOF
- Run with
go run main.go
- See
exit status 1, and nothing else
I can't just do zap.Info() since there are no such way to call those methods without L().
Expected behavior
It should simply print out the logs in order.
Additional context
-
Describe the bug
First-time Zap user here!
Zap doesn't print out any log when using
L().To Reproduce
go mod init testgo get go.uber.org/zap(v1.27.0)main.go:go run main.goexit status 1, and nothing elseI can't just do
zap.Info()since there are no such way to call those methods withoutL().Expected behavior
It should simply print out the logs in order.
Additional context
-