From 0d9c6cda3ac626d83ba266499bc47d4dcad544a3 Mon Sep 17 00:00:00 2001 From: Ti Chi Robot Date: Fri, 30 Jun 2023 11:26:11 +0800 Subject: [PATCH] session: fix bad log (#40948) (#40958) close pingcap/tidb#40947 --- session/bootstrap.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/session/bootstrap.go b/session/bootstrap.go index 960ca9fa3a625..85b54e6ac7648 100644 --- a/session/bootstrap.go +++ b/session/bootstrap.go @@ -24,7 +24,6 @@ import ( "flag" "fmt" osuser "os/user" - "runtime/debug" "strconv" "strings" "time" @@ -2084,8 +2083,7 @@ func doDMLWorks(s Session) { func mustExecute(s Session, sql string, args ...interface{}) { _, err := s.ExecuteInternal(context.Background(), sql, args...) if err != nil { - debug.PrintStack() - logutil.BgLogger().Fatal("mustExecute error", zap.Error(err)) + logutil.BgLogger().Fatal("mustExecute error", zap.Error(err), zap.Stack("stack")) } }