Files
hermes-agent/website/docs
Teknium 05b51c846c fix(process): promote waits only for the completion's owner, from effective config
Independent review of 7978c07 found two ways the wait/poll policy promised a completion
message that never arrives, so the agent ended its turn and lost the result:

- It read terminal.process_wait_auto_notify and display.background_process_notifications
  from the raw config.yaml. The completion consumers (gateway _load_gateway_config, TUI
  _load_cfg) read the effective config: managed overlay and ${VAR} expansion. A managed
  "off" or an env-expanded "off" suppressed delivery while promotion still fired, and a
  managed process_wait_auto_notify: false was ignored. Both settings now go through
  load_user_config_effective, and the gateway's HERMES_BACKGROUND_NOTIFICATIONS override
  is honoured the same way.
- It checked that the caller could receive completions, not that it would receive THIS
  one. Session B polling session A's process got the stop-polling promise; A got the
  notice. A parent polling a subagent's un-handed-off process got the promise while the
  child-owned notice is suppressed. Promotion now requires the consumers' own routing
  predicates (ProcessRegistry._owns_event on the caller's session key, then
  should_surface_notification); otherwise the caller keeps plain polling. Ownership is
  never moved to make the promise true.

Tests: a new invariant test for the foreign-session case, and the existing opt-out test
now sets the opt-out through a managed config. Both fail on 7978c07.
2026-10-17 04:35:05 -07:00
..
…