[client] Log Down-while-idle at debug instead of error

Down returns ErrServiceNotUp when the daemon is already idle, e.g. on
quit or a repeated Down. That case is harmless, so log it at debug
level and reserve the error log for real teardown failures.
This commit is contained in:
check
2026-07-20 13:18:40 +02:00
parent 8b738f0a6d
commit 811df5fe68

View File

@@ -1082,6 +1082,7 @@ func (s *Server) Down(ctx context.Context, _ *proto.DownRequest) (*proto.DownRes
if err := s.cleanupConnection(); err != nil {
s.mutex.Unlock()
if errors.Is(err, ErrServiceNotUp) {
log.Debugf("Down called while service not up: %v", err)
return nil, err
}
log.Errorf("failed to shut down properly: %v", err)