Skip to content

fix(cli): mark sessions command as cli_only - #23577

Closed
AllynSheep wants to merge 1 commit into
NousResearch:mainfrom
AllynSheep:fix/sessions-command-cli-only
Closed

fix(cli): mark sessions command as cli_only#23577
AllynSheep wants to merge 1 commit into
NousResearch:mainfrom
AllynSheep:fix/sessions-command-cli-only

Conversation

@AllynSheep

Copy link
Copy Markdown
Contributor

Summary

The /sessions slash command is registered in COMMAND_REGISTRY but has no handler in either the gateway dispatcher or the CLI dispatcher. It results in a silent no-op — the user sends /sessions and gets zero response.

Fix

Mark sessions as cli_only=True so it is excluded from GATEWAY_KNOWN_COMMANDS. The interactive session browser requires keyboard navigation and is not feasible in messaging gateways.

Changes

  • hermes_cli/commands.py: Added cli_only=True to sessions command definition

Testing

  • hermes sessions browse continues to work in CLI mode
  • Gateway now properly rejects /sessions with unknown command handling

Closes #23533

The /sessions slash command is registered in COMMAND_REGISTRY but has
no handler in either gateway/run.py or cli.py. This causes a silent
no-op — users send /sessions and get zero response.

Mark the command as cli_only=True so it is excluded from
GATEWAY_KNOWN_COMMANDS. The interactive session browser requires
keyboard navigation and is not feasible in messaging gateways.

Fixes NousResearch#23533
@alt-glitch alt-glitch added type/bug Something isn't working P3 Low — cosmetic, nice to have comp/cli CLI entry point, hermes_cli/, setup wizard comp/gateway Gateway runner, session dispatch, delivery duplicate This issue or pull request already exists labels May 11, 2026
@alt-glitch

Copy link
Copy Markdown
Collaborator

Duplicate of #22962 — both wire up /sessions handling. #22962 adds dispatch branches in process_command(); this PR marks sessions as cli_only to exclude from gateway.

@teknium1

Copy link
Copy Markdown
Contributor

Thanks for identifying the original /sessions no-op and for the duplicate discussion pointing to the dispatch-based fix.

Automated hermes-sweeper review found that current main now implements the requested behavior more completely:

  • Classic CLI dispatches /sessions in cli.py:8627 and handles listing/resume in hermes_cli/cli_commands_mixin.py:827 (introduced by d6c488f2dce96a1d1375c8e7e089b54a1e7ae6f4).
  • Gateway dispatches /sessions in gateway/run.py:9901; gateway/slash_commands.py:3693 provides a scoped session listing/resume handler (introduced by 3e7e9b24d40c6ff62e50936ba8b8184ad61da322, shipped in v2026.6.19).
  • tests/gateway/test_resume_command.py:780 verifies gateway dispatch, and the command is documented as available on both CLI and messaging gateways at website/docs/reference/slash-commands.md:257.

Marking the command CLI-only would now suppress that supported gateway behavior, so this PR is superseded by main.

@teknium1 teknium1 closed this Jul 13, 2026
@teknium1 teknium1 added the sweeper:implemented-on-main Sweeper: behavior already present on current main label Jul 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/cli CLI entry point, hermes_cli/, setup wizard comp/gateway Gateway runner, session dispatch, delivery duplicate This issue or pull request already exists P3 Low — cosmetic, nice to have sweeper:implemented-on-main Sweeper: behavior already present on current main type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bug: /sessions command is registered but has no handler — silent no-op in gateway and CLI

3 participants