Skip to content

restructure PR 3: move gateway/ → hermes_agent/gateway/ #14588

@alt-glitch

Description

@alt-glitch

Parent: #14182
Depends on: #14587 (PR 2)

Goal

Move gateway/ into hermes_agent/gateway/. First PR with a large test diff (1,224 test import refs, ~178 test files). Production callers concentrated in tools/send_message_tool.py (38 refs) and hermes_cli/gateway.py (20 refs).

What moves

All .py files under gateway/ move to hermes_agent/gateway/ preserving directory structure (~48 files including platforms/, builtin_hooks/ subdirectories).

Import rewrites

Internal: all gateway.*hermes_agent.gateway.*

External callers (68 prod refs):

  • tools/send_message_tool.py (38 refs)
  • hermes_cli/gateway.py (20 refs)
  • agent/ (2 refs)
  • hermes_agent/cron/ (4 refs — already moved, rewrite in this PR)

Test files: ~1,224 import refs across tests/gateway/ (~178 test files)

Also rewrites in this PR

  • hermes_agent/cron/ files that import from gateway.* — these lines were left as-is in PR 2 because gateway hadn't moved yet. This is the expected one-time rewrite.

pyproject.toml changes

  • REMOVE gateway, gateway.* from packages.find include

Non-.py files to check

  • scripts/hermes-gateway (no extension) — has from gateway.run import start_gateway

Verification

rg "from gateway[\. ]" --type py       # should return 0
rg "import gateway\b" --type py        # should return 0
pytest

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3Low — cosmetic, nice to havecomp/gatewayGateway runner, session dispatch, deliverytype/refactorCode restructuring, no behavior change

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions