Prechádzať zdrojové kódy

Report better warning on client closed abort of load

If the client closes the connection before we finish loading the model
we abort, so lets make the log message clearer why to help users
understand this failure mode
Daniel Hiltgen 11 mesiacov pred
rodič
commit
c4209d6d21
1 zmenil súbory, kde vykonal 1 pridanie a 1 odobranie
  1. 1 1
      llm/server.go

+ 1 - 1
llm/server.go

@@ -528,7 +528,7 @@ func (s *llmServer) WaitUntilRunning(ctx context.Context) error {
 	for {
 	for {
 		select {
 		select {
 		case <-ctx.Done():
 		case <-ctx.Done():
-			slog.Info("context expired before server started")
+			slog.Warn("client connection closed before server finished loading, aborting load")
 			return fmt.Errorf("timed out waiting for llama runner to start: %w", ctx.Err())
 			return fmt.Errorf("timed out waiting for llama runner to start: %w", ctx.Err())
 		case err := <-s.done:
 		case err := <-s.done:
 			msg := ""
 			msg := ""