print stack

This commit is contained in:
Zoltán Papp
2026-06-25 13:38:40 +02:00
parent 50ff095d68
commit b5d2f054c2
+2
View File
@@ -5,6 +5,7 @@ import (
"errors" "errors"
"fmt" "fmt"
"net/netip" "net/netip"
"runtime/debug"
"slices" "slices"
"sync" "sync"
"time" "time"
@@ -1476,5 +1477,6 @@ func (fs FullStatus) ToProto() *proto.FullStatus {
func debugElapsed(msg string, startTime time.Time) { func debugElapsed(msg string, startTime time.Time) {
if elapsed := time.Since(startTime); elapsed > 1*time.Second { if elapsed := time.Since(startTime); elapsed > 1*time.Second {
log.Infof("run %s took %s", msg, elapsed) log.Infof("run %s took %s", msg, elapsed)
debug.PrintStack()
} }
} }