Skip to content

fix: prioritize nested subparser dispatch over chat fallback - #4189

Closed
iborazzi wants to merge 7 commits into
NousResearch:mainfrom
iborazzi:fix/mcp-subparser-dispatch
Closed

fix: prioritize nested subparser dispatch over chat fallback#4189
iborazzi wants to merge 7 commits into
NousResearch:mainfrom
iborazzi:fix/mcp-subparser-dispatch

Conversation

@iborazzi

Copy link
Copy Markdown
Contributor

Fixes #4184.

The issue was caused by checking for args.command is None before attempting to dispatch args.func. This prevented nested commands (like mcp add) from executing and instead forced the user into the chat REPL.

I've moved the args.func dispatch logic to the top of the main() function and added a return to ensure execution stops once a subcommand is successfully handled.

iborazzi and others added 7 commits March 17, 2026 14:51
feat(cli): add timestamps to session list
Refactor SlackAdapter methods for improved error handling and code clarity. Update connection logic to check both SLACK_BOT_TOKEN and SLACK_APP_TOKEN. Simplify message formatting and reaction handling.
@bannert1337

Copy link
Copy Markdown

This PR is extremely bloated and touches many different parts of the code base.

@alt-glitch alt-glitch added type/bug Something isn't working P2 Medium — degraded but workaround exists comp/cli CLI entry point, hermes_cli/, setup wizard labels May 1, 2026
@alt-glitch

Copy link
Copy Markdown
Collaborator

Related to #17294 (preserve hermes mcp add command routing). Fixes #4184 (nested subparser dispatch bug).

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 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.

hermes mcp add falls through to chat REPL due to nested subparser dispatch bug

3 participants