Enha: notify user on llm resp error

This commit is contained in:
Grail Finder
2025-12-06 15:12:41 +03:00
parent b0400612bb
commit 0f3baa4f8b

3
bot.go
View File

@@ -285,6 +285,9 @@ func sendMsgToLLM(body io.Reader) {
if err != nil {
logger.Error("error parsing response body", "error", err,
"line", string(line), "url", cfg.CurrentAPI)
if err := notifyUser("LLM Response Error", "Failed to parse LLM response: "+err.Error()); err != nil {
logger.Error("failed to notify user", "error", err)
}
streamDone <- true
break
}