Skip to content

The agent that grows with you

fix(fallback): log when provider-alias collapse degrades to lowercase (reviewer)

andyst-dev4578259ddcbb
diff --git a/hermes_cli/fallback_config.py b/hermes_cli/fallback_config.py
index c66cae54287..c2a6fa66a27 100644
--- a/hermes_cli/fallback_config.py
+++ b/hermes_cli/fallback_config.py
@@ -23,6 +23,14 @@ def _normalize_provider_id(value: str) -> str:
try:
from hermes_cli.providers import normalize_provider
except Exception: # pragma: no cover - import resilience
+ # Silent degradation: alias collapse is disabled and we fall back to a
+ # bare lowercase. Log so a future import cycle/refactor can't regress
+ # the dedup invisibly.
+ logger.warning(
+ "fallback provider alias collapse degraded to lowercase: "
+ "could not import hermes_cli.providers.normalize_provider",
+ exc_info=True,
+ )
return value.lower()
return normalize_provider(value)