1
0
mirror of https://github.com/coalaura/whiskr.git synced 2025-12-02 20:22:52 +00:00

improve some error messages

This commit is contained in:
Laura
2025-11-01 23:19:27 +01:00
parent 9fa1c29365
commit 9b33b92d8e
2 changed files with 4 additions and 4 deletions

View File

@@ -404,7 +404,7 @@ func HandleChat(w http.ResponseWriter, r *http.Request) {
func RunCompletion(ctx context.Context, response *Stream, request *openrouter.ChatCompletionRequest) (*ToolCall, string, error) {
stream, err := OpenRouterStartStream(ctx, *request)
if err != nil {
return nil, "", err
return nil, "", fmt.Errorf("stream.start: %v", err)
}
defer stream.Close()
@@ -426,7 +426,7 @@ func RunCompletion(ctx context.Context, response *Stream, request *openrouter.Ch
break
}
return nil, "", err
return nil, "", fmt.Errorf("stream.receive: %v", err)
}
if id == "" {