Skip to content

fix(gateway): honor silent busy input modes - #15344

Closed
helix4u wants to merge 1 commit into
NousResearch:mainfrom
helix4u:fix/gateway-busy-input-ignore
Closed

helix4u wants to merge 1 commit into
NousResearch:mainfrom
helix4u:fix/gateway-busy-input-ignore

Conversation

@helix4u

@helix4u helix4u commented Apr 24, 2026

Copy link
Copy Markdown
Collaborator

What does this PR do?

Honors silent busy-input modes for CLI and gateway sessions.

display.busy_input_mode was only effectively supporting interrupt and queue in the gateway. Any other value, including the dashboard-exposed block option and user-configured ignore, fell back to interrupt, so busy Discord/Telegram sessions could still post "Interrupting current task..." acknowledgements and interrupt the active run.

This PR makes block and ignore explicit silent-drop modes for normal busy-session input. Dedicated mid-run controls such as /stop, /status, /approve, /deny, /queue, and /steer still work.

Related open PRs:

Related Issue

Fixes #

Type of Change

  • 🐛 Bug fix (non-breaking change that fixes an issue)
  • ✨ New feature (non-breaking change that adds functionality)
  • 🔒 Security fix
  • 📝 Documentation update
  • ✅ Tests (adding or improving test coverage)
  • ♻️ Refactor (no behavior change)
  • 🎯 New skill (bundled or hub)

Changes Made

  • gateway/run.py: accepts interrupt, queue, block, and ignore from config/env and silently drops normal busy-session input in block/ignore mode.
  • cli.py: honors block and ignore for busy Enter behavior instead of falling back to interrupt.
  • hermes_cli/web_server.py: exposes all supported busy-input modes in the settings schema.
  • website/docs/user-guide/cli.md and website/docs/user-guide/messaging/index.md: document the supported modes.
  • Tests cover gateway config loading, adapter-level busy handling, direct running-agent busy handling, and CLI config normalization.

How to Test

  1. Set display.busy_input_mode: ignore or display.busy_input_mode: block.
  2. Start a gateway session and send a normal follow-up message while the agent is still running.
  3. Confirm the follow-up does not interrupt the active run, does not get queued, and does not send a busy acknowledgement.
  4. Confirm explicit commands such as /stop and /status still work while the agent is running.

Checklist

Code

  • I've read the Contributing Guide
  • My commit messages follow Conventional Commits (fix(scope):, feat(scope):, etc.)
  • I searched for existing PRs to make sure this isn't a duplicate
  • My PR contains only changes related to this fix/feature (no unrelated commits)
  • I've run pytest tests/ -q and all tests pass
  • I've added tests for my changes (required for bug fixes, strongly encouraged for features)
  • I've tested on my platform: Ubuntu 24.04

Documentation & Housekeeping

  • I've updated relevant documentation (README, docs/, docstrings) — or N/A
  • I've updated cli-config.yaml.example if I added/changed config keys — or N/A
  • I've updated CONTRIBUTING.md or AGENTS.md if I changed architecture or workflows — or N/A
  • I've considered cross-platform impact (Windows, macOS) per the compatibility guide — or N/A
  • I've updated tool descriptions/schemas if I changed tool behavior — or N/A

Screenshots / Logs

  • ./scripts/run_tests.sh tests/gateway/test_busy_session_ack.py tests/gateway/test_restart_drain.py tests/gateway/test_session_race_guard.py tests/cli/test_cli_init.py -n 470 passed
  • ./scripts/run_tests.sh tests/ -n 4135 failed, 15357 passed, 40 skipped, 184 warnings in 304.57s

@alt-glitch alt-glitch added type/bug Something isn't working P2 Medium — degraded but workaround exists comp/gateway Gateway runner, session dispatch, delivery comp/cli CLI entry point, hermes_cli/, setup wizard area/config Config system, migrations, profiles labels Apr 24, 2026
@helix4u
helix4u marked this pull request as ready for review April 24, 2026 21:42
@teknium1

Copy link
Copy Markdown
Collaborator

Thanks for tracking this down — you correctly identified that block in the dashboard was a lie. After discussion we decided the right fix is the inverse direction: the dashboard option was added speculatively in the original web UI PR with no implementation behind it, and silent-drop behavior is actively bad UX for a messaging bot (users spam when they think the bot's broken, and queue already covers the 'don't interrupt me' case).

Removed block from the dashboard schema in #15355 (merged). The two supported modes remain interrupt (default) and queue.

Appreciate the thorough PR with tests and docs — sorry we're going the other way on this one.

@teknium1 teknium1 closed this Apr 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/config Config system, migrations, profiles comp/cli CLI entry point, hermes_cli/, setup wizard comp/gateway Gateway runner, session dispatch, delivery P2 Medium — degraded but workaround exists type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants