From c8a6b3ca949d58955076568aaaec72a7fe92d7ee Mon Sep 17 00:00:00 2001 From: KoNit-K <124019182+KoNit-K@users.noreply.github.com> Date: Mon, 14 Sep 2026 16:39:34 +0800 Subject: [PATCH] fix(gateway): keep auto_multiplex_migration spelling Rename DEFAULT_CONFIG to the documented key so the reader, docs, and defaults agree. Do not reintroduce auto_migrate. Co-authored-by: Cursor --- hermes_cli/config_defaults.py | 2 +- tests/hermes_cli/test_config.py | 3 +++ tests/hermes_cli/test_gateway_migrate_multiplex.py | 2 ++ 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/hermes_cli/config_defaults.py b/hermes_cli/config_defaults.py index c6dbf284ce..3361babaec 100644 --- a/hermes_cli/config_defaults.py +++ b/hermes_cli/config_defaults.py @@ -1972,7 +1972,7 @@ DEFAULT_CONFIG = { # Set to False to stay on per-profile gateways — a durable opt-out that survives updates, so # the decision is not re-litigated on every release. Only the AUTOMATIC path reads this: # `hermes gateway migrate --multiplex` is an explicit request and always proceeds. - "auto_migrate": True, + "auto_multiplex_migration": True, # Route inbound chats of the default profile's bots to another profile # (gateway/profile_routing.py): [{profile, platform, chat_id|user_id|guild_id|...}]. # Most-specific match wins; only read by the multiplexing default gateway. diff --git a/tests/hermes_cli/test_config.py b/tests/hermes_cli/test_config.py index 6f8058e829..ca2aedfd69 100644 --- a/tests/hermes_cli/test_config.py +++ b/tests/hermes_cli/test_config.py @@ -1933,5 +1933,8 @@ def test_gateway_multiplex_keys_are_recognized_config_keys(): from hermes_cli.config import _validate_config_key from hermes_cli.config_defaults import DEFAULT_CONFIG assert DEFAULT_CONFIG["gateway"]["multiplex_profiles"] is False + assert DEFAULT_CONFIG["gateway"]["auto_multiplex_migration"] is True + assert "auto_migrate" not in DEFAULT_CONFIG["gateway"] assert _validate_config_key("gateway.multiplex_profiles") == (True, None) assert _validate_config_key("gateway.profile_routes") == (True, None) + assert _validate_config_key("gateway.auto_multiplex_migration") == (True, None) diff --git a/tests/hermes_cli/test_gateway_migrate_multiplex.py b/tests/hermes_cli/test_gateway_migrate_multiplex.py index 3bf11f4575..1d1b4f6f91 100644 --- a/tests/hermes_cli/test_gateway_migrate_multiplex.py +++ b/tests/hermes_cli/test_gateway_migrate_multiplex.py @@ -354,6 +354,8 @@ def test_auto_multiplex_migration_false_opts_out_of_the_update_hook_but_not_the_ (fleet.root / "config.yaml").write_text( "model:\n default: x\nauto_multiplex_migration: false\n", encoding="utf-8") assert auto_migration_opted_out(fleet.root) is False + (fleet.root / "config.yaml").write_text("model:\n default: x\n", encoding="utf-8") + assert auto_migration_opted_out(fleet.root) is False (fleet.root / "config.yaml").write_text( "model:\n default: x\ngateway:\n auto_multiplex_migration: true\n", encoding="utf-8") assert auto_migration_opted_out(fleet.root) is False