mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-04-29 01:31:41 +00:00
fix: add all_profiles param + narrow exception handling
- add all_profiles=False to find_gateway_pids() and kill_gateway_processes() so hermes update and gateway stop --all can still discover processes across all profiles - narrow bare 'except Exception' to (OSError, subprocess.TimeoutExpired) - update test mocks to match new signatures
This commit is contained in:
parent
b80e318168
commit
d82580b25b
5 changed files with 28 additions and 15 deletions
|
|
@ -130,7 +130,7 @@ class TestGatewayStopCleanup:
|
|||
monkeypatch.setattr(
|
||||
gateway_cli,
|
||||
"kill_gateway_processes",
|
||||
lambda force=False: kill_calls.append(force) or 2,
|
||||
lambda force=False, all_profiles=False: kill_calls.append(force) or 2,
|
||||
)
|
||||
|
||||
gateway_cli.gateway_command(SimpleNamespace(gateway_command="stop"))
|
||||
|
|
@ -156,7 +156,7 @@ class TestGatewayStopCleanup:
|
|||
monkeypatch.setattr(
|
||||
gateway_cli,
|
||||
"kill_gateway_processes",
|
||||
lambda force=False: kill_calls.append(force) or 2,
|
||||
lambda force=False, all_profiles=False: kill_calls.append(force) or 2,
|
||||
)
|
||||
|
||||
gateway_cli.gateway_command(SimpleNamespace(gateway_command="stop", **{"all": True}))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue