mirror of
https://github.com/nesquena/hermes-webui.git
synced 2026-05-26 03:30:36 +00:00
bd8fc6a2e2
When the user explicitly selects @provider:model from the picker, _resolve_compatible_session_model() was stripping the prefix because the hint matched the active provider (hint_matches_active=True → return bare_model, True). This caused: - The picker to snap back to the first duplicate entry on next render - resolve_model_provider() to use the default provider instead of the explicitly selected one, running the agent on the wrong backend The hint_matches_active branch was intended for normalizing stale cross- provider session models. But an @provider:model where the hint IS the active provider is not stale — it is the user's deliberate selection. Fix: return (model, False) so the full @provider:model survives to resolve_model_provider() in config.py, which already handles it correctly. Updates test_active_at_provider_session_model_preserved_with_hint and adds test_issue1253_duplicate_model_id_active_provider_hint_preserved. Closes #1253