We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 78ea3b6 commit a0790e0Copy full SHA for a0790e0
pkg/log/zap/zap.go
@@ -181,7 +181,8 @@ func (o *Options) addDefaults() {
181
lvl := zap.NewAtomicLevelAt(zap.ErrorLevel)
182
o.StacktraceLevel = &lvl
183
}
184
- // Turn off sampling for all debug levels.
+ // Disable sampling when we are in debug mode. Otherwise, this will
185
+ // cause index out of bounds errors in the sampling code.
186
if o.Level.Enabled(zapcore.DebugLevel) {
187
o.ZapOpts = append(o.ZapOpts, zap.Development())
188
} else {
0 commit comments