hermes - 💡(How to fix) Fix Gateway: text messages while agent is busy are silently queued — no interrupt, no feedback [4 pull requests]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

When the agent is actively running (executing tool calls), incoming text messages from the user are silently queued with no interruption and no feedback. The user has no way to stop the agent except by using /stop. Natural language stop requests ("stop", "para", "frena") are treated as regular messages and enqueued.

Root Cause

gateway/platforms/base.py lines ~3317-3339:

When session_key in self._active_sessions and the message is not a recognized slash command (checked via should_bypass_active_session), the message enters the queue path:

if self._is_queue_text_debounce_candidate(event):
    await self._queue_text_debounce(session_key, event)
else:
    merge_pending_message_event(self._pending_messages, session_key, event, ...)
return  # Don't process now - will be handled after current task finishes

No feedback is sent to the user. No interrupt is triggered.

Fix Action

Fixed

Code Example

if self._is_queue_text_debounce_candidate(event):
    await self._queue_text_debounce(session_key, event)
else:
    merge_pending_message_event(self._pending_messages, session_key, event, ...)
return  # Don't process now - will be handled after current task finishes

---

19:08:21 INFO [Telegram] Flushing text batch ...session... (6 chars)
19:09:56 INFO [Telegram] Flushing text batch ...session... (24 chars)
19:10:49 INFO [Telegram] Flushing text batch ...session... (13 chars)
19:11:04 INFO [Telegram] Flushing text batch ...session... (4 chars)
19:11:48 INFO Invalidated run generation [...] (stop_command)  <- /stop finally worked
RAW_BUFFERClick to expand / collapse

Summary

When the agent is actively running (executing tool calls), incoming text messages from the user are silently queued with no interruption and no feedback. The user has no way to stop the agent except by using /stop. Natural language stop requests ("stop", "para", "frena") are treated as regular messages and enqueued.

Impact

High — the user loses control of the agent during long tool-call sequences. The only escape hatch is knowing about /stop, which is not discoverable in the moment.

Reproduction

  1. Send a message that triggers a multi-tool-call response (e.g. a complex coding task)
  2. While the agent is running, send a plain text message like "stop" or "wait"
  3. Observe: no feedback, no interruption. The message is queued silently.
  4. The agent continues until it finishes or /stop is used.

Root Cause

gateway/platforms/base.py lines ~3317-3339:

When session_key in self._active_sessions and the message is not a recognized slash command (checked via should_bypass_active_session), the message enters the queue path:

if self._is_queue_text_debounce_candidate(event):
    await self._queue_text_debounce(session_key, event)
else:
    merge_pending_message_event(self._pending_messages, session_key, event, ...)
return  # Don't process now - will be handled after current task finishes

No feedback is sent to the user. No interrupt is triggered.

Evidence from logs

19:08:21 INFO [Telegram] Flushing text batch ...session... (6 chars)
19:09:56 INFO [Telegram] Flushing text batch ...session... (24 chars)
19:10:49 INFO [Telegram] Flushing text batch ...session... (13 chars)
19:11:04 INFO [Telegram] Flushing text batch ...session... (4 chars)
19:11:48 INFO Invalidated run generation [...] (stop_command)  <- /stop finally worked

Four messages received and flushed but never delivered as interrupts. Only /stop broke through.

Proposed Solutions (not mutually exclusive)

  1. Feedback on queue: When a message is enqueued during an active session, send a brief acknowledgment: "⏳ Agent busy — message queued. Use /stop to interrupt."
  2. Natural stop-word detection: Recognize bare stop-intent messages (configurable list: "stop", "para", "halt", "cancel", etc.) and treat them as /stop equivalents.
  3. Configurable busy_text_mode: interrupt: Add an option where ANY incoming text interrupts the running agent (current behavior is queue-only unless busy_input_mode: steer).

Solution 1 is the minimum viable fix — the user at least knows their message did not interrupt anything.

Environment

  • Hermes Agent (latest main as of 2026-05-24)
  • Platform: Telegram DM
  • Model: claude-opus-4.6 via gateway

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

hermes - 💡(How to fix) Fix Gateway: text messages while agent is busy are silently queued — no interrupt, no feedback [4 pull requests]