mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-07-08 13:12:08 +00:00
fix: strip tool progress display modes
This commit is contained in:
parent
fddc95f4c2
commit
46fbd73f66
2 changed files with 7 additions and 1 deletions
|
|
@ -233,7 +233,7 @@ def _normalise(setting: str, value: Any) -> Any:
|
|||
return "off"
|
||||
if value is True:
|
||||
return "all"
|
||||
val = str(value).lower()
|
||||
val = str(value).strip().lower()
|
||||
return val if val in {"off", "new", "all", "verbose"} else "all"
|
||||
if setting in {
|
||||
"show_reasoning",
|
||||
|
|
|
|||
|
|
@ -155,6 +155,12 @@ class TestYAMLNormalisation:
|
|||
config = {"display": {"platforms": {"whatsapp": {"tool_progress": "generic"}}}}
|
||||
assert resolve_display_setting(config, "whatsapp", "tool_progress") == "all"
|
||||
|
||||
def test_tool_progress_mode_strips_whitespace(self):
|
||||
from gateway.display_config import resolve_display_setting
|
||||
|
||||
config = {"display": {"platforms": {"whatsapp": {"tool_progress": " off\n"}}}}
|
||||
assert resolve_display_setting(config, "whatsapp", "tool_progress") == "off"
|
||||
|
||||
def test_only_long_running_visibility_accepts_generic_mode(self):
|
||||
from gateway.display_config import resolve_display_setting
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue