mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-07-15 14:22:43 +00:00
Two invariants layered on the origin-routing commit (#55578): 1. Fail closed on orphaned async-delegation payloads. The poller's belongs-elsewhere check handles events owned by another LIVE session, but an event whose owner is gone previously fell through and was adopted by whichever poller saw it - injecting one chat's delegation output into another chat. Delegation completions are now injected only into a session that PROVABLY owns them (origin UI id, or session-key/lineage match via the compression chain); unowned payloads are dropped from injection with a WARNING (the subagent's output is already persisted in the delegation records, so nothing is lost). The shutdown drain applies the same rule. Non-delegation events keep the historical adopt-orphans behavior. 2. A session's in-flight async delegations end with the session. _finalize_session now calls interrupt_for_session(): delegations commissioned by the closing UI session are interrupted always; key-matched delegations only when the TUI owns the session lifecycle, so closing a viewer tab on a live gateway session never kills the gateway's own background work. |
||
|---|---|---|
| .. | ||
| __init__.py | ||
| test_billing_rpc.py | ||
| test_compaction_status.py | ||
| test_custom_provider_session_persistence.py | ||
| test_delegation_session_lifecycle.py | ||
| test_entry_sys_path.py | ||
| test_finalize_session_persist.py | ||
| test_gateway_owned_session_reap.py | ||
| test_goal_command.py | ||
| test_inline_rpc_gil_starvation.py | ||
| test_make_agent_provider.py | ||
| test_mcp_late_refresh_thread_owner.py | ||
| test_moa_reference_emit.py | ||
| test_model_switch_marker_role.py | ||
| test_pet_generate_rpc.py | ||
| test_project_tree.py | ||
| test_projects_rpc.py | ||
| test_protocol.py | ||
| test_reasoning_session_scope.py | ||
| test_render.py | ||
| test_review_summary_callback.py | ||
| test_session_platform_resolution.py | ||
| test_slash_worker_ansi.py | ||
| test_slash_worker_profile_home.py | ||
| test_slash_worker_sys_path.py | ||
| test_subagent_child_mirror.py | ||
| test_undo_command.py | ||
| test_wait_for_mcp_discovery.py | ||