Skip to content

Commit 23c448c

Browse files
committed
log: reduce max chars per line to 300
1 parent 7c5ae72 commit 23c448c

2 files changed

Lines changed: 2 additions & 3 deletions

File tree

intra/log/log.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,6 @@ func C(msg string, scratch []byte) {
145145
// U logs a user message (notifies the user).
146146
func U(msg string) {
147147
Glogger.Usr(msg)
148-
149148
}
150149

151150
// T logs the stack trace of the current goroutine.

intra/log/logger.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ const similarTraceThreshold = 8
189189
const similarUsrMsgThreshold = 3
190190

191191
// charsPerLine is max no. of characters per log line.
192-
const charsPerLine = 4500
192+
const charsPerLine = 300
193193

194194
// spamMsgThreshold is the min. no. of spammy msgs to report.
195195
var spammsgThreshold = [NONE + 1]uint32{
@@ -452,7 +452,7 @@ func (l *simpleLogger) msgstr(lvl LogLevel, f string, args ...any) (msg string)
452452
return level + l.tag + f
453453
}
454454
msg = fmt.Sprintf(f, args...)
455-
if len(msg) <= charsPerLine {
455+
if len(msg) <= charsPerLine { // excl tag+level
456456
return level + l.tag + msg
457457
}
458458

0 commit comments

Comments
 (0)