diff --git a/internal/tui/components/chat/editor/editor.go b/internal/tui/components/chat/editor/editor.go index 4da6ec84e56e2350f846e777175ab503d3f77437..6c2766b85077c08b45efc049fdb73f7973a767c0 100644 --- a/internal/tui/components/chat/editor/editor.go +++ b/internal/tui/components/chat/editor/editor.go @@ -3,6 +3,7 @@ package editor import ( "context" "fmt" + "log/slog" "math/rand" "net/http" "os" @@ -199,8 +200,8 @@ func (m *editorCmp) Update(msg tea.Msg) (util.Model, tea.Cmd) { } msgs, err := m.getUserMessagesAsText() if err != nil { - // TODO(tauraamui): handle error for loading history better in the UI later - panic(err) + slog.Error("failed to acquire all sessions message history", "error", err) + return m, nil } if len(msgs) == 0 { break