prevent the editor when agent busy
commitd7569d79c6da1437fe46343ed13810df6c8cae1f
authorKujtim Hoxha <kujtimii.h@gmail.com>
dateMon 21 Apr 2025, 16:50 (2 years ago)
parented3518d
internal/tui/components/chat/editor.go+3
@@ -132,6 +132,9 @@ func (m *editorCmp) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
132132 }
133133 case tea.KeyMsg:
134134 if key.Matches(msg, focusedKeyMaps.OpenEditor) {
135+ if m.app.CoderAgent.IsSessionBusy(m.session.ID) {
136+ return m, util.ReportWarn("Agent is working, please wait...")
137+ }
135138 return m, openEditor()
136139 }
137140 // if the key does not match any binding, return