Skip to content

fix: plugin toolsets invisible in hermes tools and standalone processes#3457

Merged
teknium1 merged 1 commit intomainfrom
hermes/hermes-37947bdb
Mar 27, 2026
Merged

fix: plugin toolsets invisible in hermes tools and standalone processes#3457
teknium1 merged 1 commit intomainfrom
hermes/hermes-37947bdb

Conversation

@teknium1
Copy link
Copy Markdown
Contributor

Summary

Plugin toolsets never appeared in the hermes tools TUI or any standalone process that reads plugin state without first importing model_tools.py.

Root cause: discover_plugins() only runs as a side effect of importing model_tools.py (line 181-182). The hermes tools command and _get_platform_tools() call get_plugin_toolsets() / _get_plugin_toolset_keys() without ensuring plugins have been discovered first. The plugin manager singleton exists but has never scanned ~/.hermes/plugins/, so _plugin_tool_names is empty and all plugin queries return [].

Impact:

  • hermes tools TUI never shows plugin toolsets — users can't see or toggle them
  • Any standalone process that reads plugin state before model_tools.py is imported misses plugin toolsets

Fix: Call discover_plugins() (idempotent — checks _discovered flag) in both _get_plugin_toolset_keys() and _get_effective_configurable_toolsets() before accessing plugin state. In the gateway/CLI where model_tools.py is already imported, the call is a no-op.

Context

Reported by community member (pistrie) on Discord — installed two plugins (brave-search, web-extract), /plugins showed them loaded, but they never appeared in hermes tools output or in the agent's tool list.

Test plan

  • python3 -m pytest tests/hermes_cli/test_tools_config.py tests/test_plugins.py -o 'addopts=' -q — 29 passed
hermes tools and _get_platform_tools() call get_plugin_toolsets() /
_get_plugin_toolset_keys() without first ensuring plugins have been
discovered. discover_plugins() only runs as a side effect of importing
model_tools.py, which hermes tools never does. This means:

- hermes tools TUI never shows plugin toolsets (invisible to users)
- _get_platform_tools() in standalone processes misses plugin toolsets

Fix: call discover_plugins() (idempotent) in both
_get_plugin_toolset_keys() and _get_effective_configurable_toolsets()
before accessing plugin state. In the gateway/CLI where model_tools.py
is already imported, the call is a no-op (discover_and_load checks
_discovered flag).
@github-actions
Copy link
Copy Markdown

⚠️ Supply Chain Risk Detected

This PR contains patterns commonly associated with supply chain attacks. This does not mean the PR is malicious — but these patterns require careful human review before merging.

⚠️ WARNING: Install hook files modified

These files can execute code during package installation or interpreter startup.

Files:

hermes_cli/setup.py

Automated scan triggered by supply-chain-audit. If this is a false positive, a maintainer can approve after manual review.

@teknium1 teknium1 merged commit b6b87de into main Mar 27, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

1 participant