fix(slack): exclude reserved Slack commands from native slash manifest#18456
Closed
priveperfumes wants to merge 1 commit into
Closed
fix(slack): exclude reserved Slack commands from native slash manifest#18456priveperfumes wants to merge 1 commit into
priveperfumes wants to merge 1 commit into
Conversation
Slack has built-in slash commands (e.g. /status, /me, /join) that apps cannot register. When running `hermes slack manifest --write`, the generated manifest included /status, causing Slack to reject the entire manifest with a reserved-command error. Add _SLACK_RESERVED_COMMANDS frozenset of all known Slack built-ins and skip them in slack_native_slashes(). Affected commands remain reachable via /hermes <command>. Tests updated: - New test_excludes_slack_reserved_commands validates no leaks - test_includes_canonical_commands no longer asserts /status - test_telegram_parity accounts for expected Slack-only exclusions
Contributor
Author
CI StatusThe
None of these touch |
|
Ran into. this issue personally while setting up a Slack bot using the auto-generated manifest. Had to change /status name due to a conflict with existing Slack commands not allowing this name. |
Collaborator
|
Merged via PR #18553. Your commit was cherry-picked onto current main with your authorship preserved (rebase merge). Thanks for the contribution! 🎉 |
kshitijk4poor
added a commit
that referenced
this pull request
May 1, 2026
donald131
pushed a commit
to donald131/hermes-agent
that referenced
this pull request
May 2, 2026
Adds email→username mappings for: - priveperfumes (PR NousResearch#18456) - amroessam (PR NousResearch#17798) - Hinotoi-agent (PR NousResearch#9361) - valda (PR NousResearch#14932)
nickdlkk
pushed a commit
to nickdlkk/hermes-agent
that referenced
this pull request
May 11, 2026
Adds email→username mappings for: - priveperfumes (PR NousResearch#18456) - amroessam (PR NousResearch#17798) - Hinotoi-agent (PR NousResearch#9361) - valda (PR NousResearch#14932)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
When running
hermes slack manifest --write, the generated JSON manifest includes/statusas a slash command. Slack rejects the manifest because/statusis a built-in Slack command that apps cannot register.This was introduced in #16164 which surfaces all gateway commands as native Slack slashes.
The fix adds a
_SLACK_RESERVED_COMMANDSfrozenset of all known Slack built-in slash commands and skips them inslack_native_slashes(). Affected commands remain reachable via/hermes <command>.Related Issue
No existing issue — discovered during app setup.
Type of Change
Changes Made
hermes_cli/commands.py— Added_SLACK_RESERVED_COMMANDSfrozenset (19 built-ins:/status,/me,/join,/away,/dnd,/shrug,/remind,/msg,/feed,/who,/collapse,/expand,/leave,/open,/search,/topic,/mute,/pro,/shortcuts). Added guard inslack_native_slashes()_add()closure to skip reserved names. Updated docstring.tests/hermes_cli/test_commands.py— Newtest_excludes_slack_reserved_commands. Updatedtest_includes_canonical_commands(removed/statusfrom expected set). Updatedtest_telegram_parityto exclude reserved commands from parity check.How to Test
pytest tests/hermes_cli/test_commands.py::TestSlackNativeSlashes -v— all 9 tests passpytest tests/hermes_cli/test_commands.py::TestSlackAppManifest -v— all 4 tests passpython3 -c "from hermes_cli.commands import slack_native_slashes; names = {n for n,_,_ in slack_native_slashes()}; print('status' in names)"— should printFalseChecklist
Code
fix(scope):,feat(scope):, etc.)pytest tests/ -qand all tests passDocumentation & Housekeeping
docs/, docstrings) — or N/Acli-config.yaml.exampleif I added/changed config keys — or N/ACONTRIBUTING.mdorAGENTS.mdif I changed architecture or workflows — or N/AReferences