Skip to content

[Bug]: Discord gateway adapter not registered/discovered in PyPI v0.15.1 #34511

Closed

Description

@root69cy

Bug Description

After updating hermes-agent from PyPI to v0.15.1, CLI chat/model calls work again, but the Discord gateway no longer works.

Before the update, Discord gateway was working normally. After the update:

  • Discord bot appears offline
  • Hermes does not reply in Discord
  • hermes setup gateway does not list Discord as an available platform
  • hermes gateway run logs No adapter available for discord

This looks like a PyPI packaging/plugin registration issue. The Discord adapter file exists in the installed package and imports correctly, but no hermes_agent.plugins entry points are present, so the gateway does not discover/register the Discord adapter.

Steps to Reproduce

  1. Install/update Hermes from PyPI using pipx.
  2. Confirm version is hermes-agent 0.15.1.
  3. Have an existing Discord gateway configuration with DISCORD_BOT_TOKEN configured in ~/.hermes/.env.
  4. Stop the gateway service
  5. Load the Hermes environment manually:
set -a
source ~/.hermes/.env
set +a
  1. Confirm the Discord token exists in the shell.
  2. Run the gateway manually: hermes gateway run
  3. Observe:
WARNING gateway.run: No adapter available for discord
WARNING gateway.run: No adapter could be created for any of the 1 configured platform(s). Check that required dependencies are installed and credentials are set. Gateway will continue for cron job execution.
  1. Also run the below and see that Discord is not listed as an available messaging platform:
    hermes setup gateway

Expected Behavior

Since:

  • DISCORD_BOT_TOKEN is configured
  • Discord dependencies are installed
  • plugins.platforms.discord.adapter imports successfully
  • DISCORD_AVAILABLE=True
  • register(ctx) exists and calls ctx.register_platform(name="discord", ...)

Hermes should discover/register the Discord adapter and connect the Discord gateway.

hermes setup gateway should list Discord as an available platform.

hermes gateway run should create the Discord adapter and bring the bot online.

Actual Behavior

Running the gateway manually with the environment loaded.

Output:


┌─────────────────────────────────────────────────────────┐
│           ⚕ Hermes Gateway Starting...                 │
├─────────────────────────────────────────────────────────┤
│  Messaging platforms + cron scheduler                    │
│  Press Ctrl+C to stop                                   │
└─────────────────────────────────────────────────────────┘

WARNING gateway.run: No adapter available for discord
WARNING gateway.run: No adapter could be created for any of the 1 configured platform(s). Check that required dependencies are installed and credentials are set. Gateway will continue for cron job execution.

The same warning appears in the systemd user service logs.

hermes setup gateway also does not list Discord as an available platform.

Affected Component

Gateway (Telegram/Discord/Slack/WhatsApp)

Messaging Platform (if gateway-related)

Discord

Debug Report

Report       https://paste.rs/8hzvI
agent.log    https://paste.rs/axlKa
gateway.log  https://paste.rs/A5Zgl

Operating System

Ubuntu 24.04 LTS

Python Version

3.12.3

Hermes Version

0.15.1

Additional Logs / Traceback (optional)

Final entry point check:

echo "=== Hermes package entry_points ==="
cat /home/ubuntu-user/.local/share/pipx/venvs/hermes-agent/lib/python3.12/site-packages/hermes_agent-0.15.1.dist-info/entry_points.txt

echo
echo "=== Plugin entry points visible to Python ==="
/home/ubuntu-user/.local/share/pipx/venvs/hermes-agent/bin/python - <<'PY'
import importlib.metadata as md

eps = md.entry_points()
group = "hermes_agent.plugins"

try:
    selected = eps.select(group=group)
except Exception:
    selected = eps.get(group, [])

for ep in selected:
    print(f"{ep.name} = {ep.value}")
PY


Output:


=== Hermes package entry_points === 
[console_scripts] 
hermes = hermes_cli.main:main 
hermes-acp = acp_adapter.entry:main 
hermes-agent = run_agent:main 
=== Plugin entry points visible to Python ===


The Discord adapter module is present and exposes a plugin registration function:

import plugins.platforms.discord.adapter as a 

print(a.__file__) 
print(hasattr(a, "register"))


Output:
/home/ubuntu-user/.local/share/pipx/venvs/hermes-agent/lib/python3.12/site-packages/plugins/platforms/discord/adapter.py True

So the installed PyPI package contains the Discord adapter and its register(ctx) entry function, but the package metadata exposes no hermes_agent.plugins entry points for discovery.

Root Cause Analysis (optional)

The PyPI v0.15.1 package appears to include the Discord adapter files, but the package metadata does not include any hermes_agent.plugins entry points.

The Discord adapter exists and includes:

def register(ctx) -> None: 
    ctx.register_platform( name="discord", label="Discord", ... )
        name="discord",
        label="Discord",
        ...

And Python sees no plugin entry points for hermes_agent.plugins.

This likely prevents the plugin loader from discovering/registering plugins.platforms.discord.adapter.

Suspected regression: PyPI packaging/plugin entry points missing in v0.15.1.

Proposed Fix (optional)

Ensure the PyPI package metadata includes the required hermes_agent.plugins entry points for bundled plugins, including the Discord platform adapter.

For Discord specifically, the package likely needs an entry point similar to:

discord = plugins.platforms.discord.adapter

under the hermes_agent.plugins group, assuming that is the intended plugin discovery mechanism.

Also verify that other bundled platform plugins are included in the same entry point group if they are expected to appear in hermes setup gateway.

Are you willing to submit a PR for this?

  • I'd like to fix this myself and submit a PR

Activity

  1. Bartok9 commented on May 29, 2026

    @Bartok9

    This is already fixed on main by #34484 (merged 2026-05-29 08:23 UTC, ~35 min before this issue was filed). Sharing the verification in case it helps.

    Root cause is packaging, not entry points. Bundled platform adapters are discovered via a filesystem scan for plugin.yaml/plugin.yml manifests (hermes_cli/plugins.py → _scan_directory(plugins/platforms)), not via hermes_agent.plugins entry points. So the missing hermes_agent.plugins group you observed is expected — that group isn't the discovery mechanism for bundled platforms. The actual regression: the v0.15.0/v0.15.1 wheel shipped every adapter's Python code but none of the plugin.yaml manifests, so the scan found zero plugins and every gateway platform fell back to No adapter available for <platform>.

    Why your install has adapter.py but no manifest: the wheel's package-data only declared dashboard assets, so *.py files were collected (as package modules) while plugin.yaml was silently dropped.

    #34484 fixes both packaging channels:

    • wheel: [tool.setuptools.package-data] plugins += **/plugin.yaml, **/plugin.yml
    • sdist: MANIFEST.in recursive-include plugins plugin.yaml plugin.yml (for Homebrew/downstream)

    Verified on current main by building the wheel and inspecting it:

    $ python3 -m build --wheel
    $ unzip -l dist/hermes_agent-*.whl | grep -c plugin.yaml
    69          # was 0 on v0.15.1
    
    $ unzip -l dist/hermes_agent-*.whl | grep platforms/discord
      plugins/platforms/discord/__init__.py
      plugins/platforms/discord/adapter.py
      plugins/platforms/discord/plugin.yaml   # <-- now ships
    

    All 69 source manifests are present in the wheel (comm -23 of source vs wheel manifests = empty).

    Resolution: the fix is on main but not yet in a PyPI release (v0.15.1 is the latest tag and predates it). Options until the next release cuts:

    1. Wait for the next PyPI release (will include fix(packaging): ship bundled plugin.yaml manifests in wheel and sdist #34484), or
    2. Install from git: pipx install "git+https://github.com/NousResearch/hermes-agent@main", or
    3. As a stopgap on v0.15.1, manually drop a plugin.yaml into the installed plugins/platforms/discord/ directory (copy from the repo) — discovery will then pick it up.

    cc the maintainers — this can probably be closed as fixed-on-main / dup of #34034 once the next release ships.

  2. added
    type/bugSomething isn't working
    P1High — major feature broken, no workaround
    comp/gatewayGateway runner, session dispatch, delivery
    comp/pluginsPlugin system and bundled plugins
    on May 29, 2026
  3. alt-glitch commented on May 29, 2026

    @alt-glitch

    Likely duplicate of #34034 (v0.15.0 plugin.yaml manifests missing from PyPI package). The fix was merged in #34484 — please try updating to the latest release or installing from main.

  4. root69cy commented on May 29, 2026

    @root69cy
    Author

    @

    Likely duplicate of #34034 (v0.15.0 plugin.yaml manifests missing from PyPI package). The fix was merged in #34484 — please try updating to the latest release or installing from main.

    Fix has not yet been pushed to PyPI though.

  5. teknium1 commented on May 29, 2026

    @teknium1
    Collaborator

    Fixed already

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1High — major feature broken, no workaroundcomp/gatewayGateway runner, session dispatch, deliverycomp/pluginsPlugin system and bundled pluginsplatform/discordDiscord bot adaptertype/bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions