Skip to content

fix(gateway): respect explicit plugin platform disables - #31665

Closed
ben-z wants to merge 1 commit into
NousResearch:mainfrom
ben-z:fix/respect-plugin-platform-disables
Closed

fix(gateway): respect explicit plugin platform disables#31665
ben-z wants to merge 1 commit into
NousResearch:mainfrom
ben-z:fix/respect-plugin-platform-disables

Conversation

@ben-z

@ben-z ben-z commented May 24, 2026

Copy link
Copy Markdown

Summary

  • Preserve explicit platform enabled state for all YAML platform configs, not only Slack
  • Skip plugin auto-enable when a platform was explicitly disabled
  • Add a Discord regression test covering discord.enabled: false with YAML env bridging

Test Plan

  • /Users/ben/.hermes/hermes-agent/venv/bin/python -m pytest tests/gateway/test_config.py -q -o 'addopts='
  • git diff --check

@alt-glitch alt-glitch added type/bug Something isn't working P2 Medium — degraded but workaround exists comp/gateway Gateway runner, session dispatch, delivery comp/plugins Plugin system and bundled plugins duplicate This issue or pull request already exists labels May 24, 2026
@alt-glitch

Copy link
Copy Markdown
Collaborator

Duplicate of #31596 — same fix target (_apply_env_overrides() ignoring explicit enabled: false for plugin platforms). #31596 is already triaged and linked to the root cause family (#30736, #31109, #30803). Also competing with #18418 (Telegram variant) and #31468 (Feishu variant).

@Morad37

Morad37 commented May 24, 2026

Copy link
Copy Markdown
Contributor

Clean fix. The marker was being consumed by without checking whether the user had explicitly set in config. The extra guard preserves the user's explicit disable while still letting env-var auto-enable work for platforms that weren't configured at all.

The test covers the exact regression case -- config has but no token env var, so auto-enable would have overridden it before this fix.

@teknium1

Copy link
Copy Markdown
Contributor

Thanks for the focused gateway regression fix. This automated hermes-sweeper review found that its exact guarantee is already implemented on current main.

  • gateway/config.py:1255-1266 records _enabled_explicit for every platform configuration that explicitly supplies enabled, extending beyond the Slack-only behavior in this PR's base.
  • gateway/config.py:2148-2161 skips registry-driven plugin auto-enablement when the platform is explicitly disabled, including the token/SDK-present path described in the PR.
  • Current regression coverage in tests/gateway/test_slack_mention.py:515-563 verifies explicit disable wins over an environment token for both top-level and nested platform YAML.
  • Commit 5600105478ffde29d7566b45421b100eaa29c4ef carried this behavior through the bundled-platform migration; it shipped in v2026.7.1.

This also matches the duplicate relationship noted in the discussion with #31596.

@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/gateway Gateway runner, session dispatch, delivery comp/plugins Plugin system and bundled plugins duplicate This issue or pull request already exists P2 Medium — degraded but workaround exists 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.

4 participants