Skip to content

Bug: dashboard chat handler leaks tui_gateway.slash_worker processes after each gateway turn #21370

@akamel001

Description

@akamel001

Summary

hermes dashboard spawns tui_gateway.slash_worker subprocesses per chat turn (including turns routed in from gateway platforms like Telegram), but does not reap them after the response is delivered. Workers accumulate as idle processes holding session state.

Repro

  1. Run hermes dashboard with the gateway attached to a chat platform (e.g. Telegram).
  2. Send N messages through the platform. Do not open a TUI session.
  3. pgrep -af tui_gateway.slash_worker → N processes, one per turn, parented to the hermes dashboard PID, all idle.

Expected

Worker exits (or returns to a bounded pool with idle eviction) after delivering its turn's response.

Actual

Worker stays resident indefinitely. Each idle worker holds ~5MB RSS + ~80MB swap of cold session state. Linear growth with chat volume.

Suspected cause

slash_worker likely awaits a follow-up message on its IPC channel that only the TUI sends. When the dashboard chat path invokes it for a one-shot turn, nothing ever closes the channel, so the worker blocks forever.

Workaround

pkill -f tui_gateway.slash_worker — safe, next turn spawns fresh.

Related

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Medium — degraded but workaround existscomp/gatewayGateway runner, session dispatch, deliverycomp/tuiTerminal UI (ui-tui/ + tui_gateway/)sweeper:implemented-on-mainSweeper: behavior already present on current maintype/bugSomething isn't working

    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