The agent that grows with you
Python aiai-agentai-agentsanthropicchatgptclaudeclaude-codecodexhermeshermes-agentllmnous-researchopenai
fix(gateway): every daemon launcher boots again after the main merge
teknium1280cf2df2f0f
diff --git a/gateway/run_bootstrap.py b/gateway/run_bootstrap.pyindex 6e8a584084d..7f6c8a4f9c0 100644--- a/gateway/run_bootstrap.py+++ b/gateway/run_bootstrap.py@@ -273,6 +273,9 @@ async def _start_gateway_start_control_socket(runner):_control_server = Noneelse:atexit.register(_control_server.cleanup_files)+ # Hosted-room transports install onto this listener; bind it here so every launcher+ # that starts the control socket (not only start_gateway) exposes it.+ runner.session_control_server = _control_serverexcept Exception as _cs_exc:logger.debug("Control socket startup failed (non-fatal): %s", _cs_exc)_control_server = None@@ -540,7 +543,6 @@ async def start_gateway(config: Optional[GatewayConfig] = None, replace: bool =_control_server = await _start_gateway_start_control_socket(runner)if _control_server is None:raise RuntimeError("gateway session bootstrap control listener unavailable")- runner.session_control_server = _control_serverfrom gateway.run_runtime import start_gateway_runtime_apiawait start_gateway_runtime_api(runner)diff --git a/tests/gateway/test_session_operator_scope.py b/tests/gateway/test_session_operator_scope.pyindex 157d2b81b7c..75e1eea44d5 100644--- a/tests/gateway/test_session_operator_scope.py+++ b/tests/gateway/test_session_operator_scope.py@@ -86,7 +86,8 @@ async def test_identity_fields_cannot_grant_operator_or_first_claim(tmp_path, momonkeypatch.setattr(run, '_load_gateway_config', lambda: {'platform_toolsets': {'cli': []}})store = SessionStore(tmp_path / 'sessions', GatewayConfig())- runner = SimpleNamespace(session_store=store, _session_db=store._db, adapters={}, _draining=False)+ runner = SimpleNamespace(session_store=store, _session_db=store._db, adapters={}, _draining=False,+ _cached_agent_for=lambda route: None)authority = await initialize_session_authority(runner, profile_id=str(tmp_path), instance_id='fixture')owner = Principal('owner', str(tmp_path), frozenset({'session:create'}), 'owner')ref = create_local_session(authority, owner, {'request_id': 'owner', 'source': 'gui',diff --git a/tools/terminal_scope.py b/tools/terminal_scope.pyindex a08973d0b82..2b187784e32 100644--- a/tools/terminal_scope.py+++ b/tools/terminal_scope.py@@ -149,7 +149,7 @@ def build_profile_terminal_scope(hermes_home: "Any") -> Dict[str, str]:raise TerminalPolicyUnavailable(f"cannot parse {config_path}: {exc}") from excraw_terminal = raw.get("terminal") if isinstance(raw, dict) else Noneif isinstance(raw_terminal, dict):- _apply(raw_terminal)+ _apply_terminal_mapping(scope, raw_terminal)_resolve_scope_cwd_placeholder(scope)return scope