Skip to content

fix(plugins): use path keys for bundled platform plugins#27240

Open
felix-windsor wants to merge 1 commit into
NousResearch:mainfrom
felix-windsor:felix/fix-platform-plugin-path-keys
Open

fix(plugins): use path keys for bundled platform plugins#27240
felix-windsor wants to merge 1 commit into
NousResearch:mainfrom
felix-windsor:felix/fix-platform-plugin-path-keys

Conversation

@felix-windsor

Copy link
Copy Markdown
Contributor

Summary

  • scan bundled plugins/platforms/* with the same path-derived key shape used by the general plugin scanner
  • make bundled platform plugins register as platforms/<name> instead of bare manifest names like teams-platform
  • add a regression test covering the Teams platform plugin key

Why

hermes plugins list and the docs surface sub-category plugins by path key, for example platforms/teams. Runtime discovery scanned the bundled plugins/platforms directory as a separate root, so PluginManager recorded the same plugin as teams-platform. That made runtime state diverge from the key users see in plugin management surfaces.

Open PR overlap checked

Verification

  • ./scripts/run_tests.sh tests/hermes_cli/test_plugin_scanner_recursion.py::TestBundledBackendAutoLoad::test_bundled_platform_plugins_use_path_derived_keys tests/hermes_cli/test_plugin_scanner_recursion.py::TestBundledBackendAutoLoad::test_bundled_image_gen_openai_autoloads tests/gateway/test_plugin_platform_interface.py
  • ./scripts/run_tests.sh tests/hermes_cli/test_plugin_scanner_recursion.py
  • .venv/bin/ruff check hermes_cli/plugins.py tests/hermes_cli/test_plugin_scanner_recursion.py
  • git diff --check

@cardtest15-coder

This comment was marked as spam.

@alt-glitch alt-glitch added type/bug Something isn't working P3 Low — cosmetic, nice to have comp/plugins Plugin system and bundled plugins comp/cli CLI entry point, hermes_cli/, setup wizard labels May 17, 2026
@cardtest15-coder

This comment was marked as spam.

@felix-windsor felix-windsor force-pushed the felix/fix-platform-plugin-path-keys branch from 811239b to 4b28b21 Compare May 17, 2026 10:57
@felix-windsor felix-windsor marked this pull request as ready for review May 17, 2026 10:57
@felix-windsor

Copy link
Copy Markdown
Contributor Author

Rebased on latest main and force-pushed the branch.

Local verification:

  • ./scripts/run_tests.sh tests/hermes_cli/test_plugin_scanner_recursion.py::TestBundledBackendAutoLoad::test_bundled_platform_plugins_use_path_derived_keys tests/hermes_cli/test_plugin_scanner_recursion.py::TestBundledBackendAutoLoad::test_bundled_image_gen_openai_autoloads tests/gateway/test_plugin_platform_interface.py

Marked ready for review.

@felix-windsor felix-windsor force-pushed the felix/fix-platform-plugin-path-keys branch from 4b28b21 to a1fc963 Compare May 18, 2026 02:15
@felix-windsor

Copy link
Copy Markdown
Contributor Author

Rebased on latest main (as of 2026-05-18) and force-pushed.

Local verification:

  • ./scripts/run_tests.sh tests/hermes_cli/test_plugin_scanner_recursion.py::TestBundledBackendAutoLoad::test_bundled_platform_plugins_use_path_derived_keys

(Still seeing no CI statuses reported on the PR head; may need maintainer Actions approval for fork PRs.)

@felix-windsor felix-windsor force-pushed the felix/fix-platform-plugin-path-keys branch from a1fc963 to fd2eaf7 Compare May 19, 2026 03:13
@teknium1

Copy link
Copy Markdown
Contributor

Thanks for the focused fix. I verified the premise still holds on current main: PluginManager scans repo_plugins / "platforms" as a separate root at hermes_cli/plugins.py:1186, and _parse_manifest falls back to the manifest name when prefix is empty at hermes_cli/plugins.py:1405. With plugins/platforms/teams/plugin.yaml:1 declaring name: teams-platform, runtime discovery registers teams-platform.

The plugin-management CLI takes the other path: _scan_level recurses from the bundled plugins root and builds sub_prefix from directories at hermes_cli/plugins_cmd.py:876, so the same plugin is surfaced as platforms/teams. The PR’s diff changes the bundled-platform runtime scan to pass prefix="platforms" and adds a regression assertion for platforms/teams, which matches the existing key model without adding new plugin surface or core tool footprint.

I did not find a blocker in this diff. This is an automated hermes-sweeper review.

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/plugins Plugin system and bundled plugins P3 Low — cosmetic, nice to have type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants