mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-07-29 18:46:59 +00:00
Importing tui_gateway.entry from a worker thread raised 'ValueError: signal only works in main thread of the main interpreter' because signal.signal() was called unconditionally at import time. On the Desktop/WebSocket path, server._build() runs in a daemon thread and does 'from tui_gateway.entry import ensure_mcp_discovery_started' as the first import of entry (entry.main() is never run there), which crashed and aborted MCP discovery startup — every session then lost its MCP servers (e.g. Dart-mcp) with ClosedResourceError. signal handlers are process-global, so installing them only when the module is first imported in the main thread is sufficient; importing from a worker thread becomes a safe no-op. Fixes #72667 |
||
|---|---|---|
| .. | ||
| __init__.py | ||
| _stdin_recovery.py | ||
| compute_host.py | ||
| entry.py | ||
| event_publisher.py | ||
| git_probe.py | ||
| host_supervisor.py | ||
| loop_noise.py | ||
| project_tree.py | ||
| render.py | ||
| server.py | ||
| slash_worker.py | ||
| synthetic_turn.py | ||
| transport.py | ||
| turn_marker.py | ||
| ws.py | ||