fix: preserve named custom vision providers - #31792
Conversation
|
Duplicate of #26544 which implements the same fix — preserving the |
teknium1
left a comment
There was a problem hiding this comment.
Thanks for the focused fix. The current vision path still strips custom: at agent/auxiliary_client.py:5289; because _PROVIDER_ALIASES maps moonshot to kimi-coding at :254-255, custom:moonshot is routed as the built-in identity before _get_cached_client() is called at :5456-5461. Preserving the explicit named-custom identifier fits the existing resolver, which accepts custom:<name> at hermes_cli/runtime_provider.py:640-674.
Problems
tests/agent/test_auxiliary_named_custom_providers.py:60-65verifies only the private normalization result. It does not verify that the configured custom endpoint wins in the complete vision-resolution path.
Suggested changes
- Add a regression test configuring
auxiliary.vision.provider: custom:moonshotand a matching custom-provider endpoint, then assertresolve_vision_provider_client()constructs the client for that endpoint rather than the built-in Kimi route.
Automated hermes-sweeper review.
| @@ -60,7 +60,11 @@ def test_bare_provider_name_unchanged(self): | |||
|
|
|||
| def test_custom_colon_named_provider_preserved(self): | |||
| from agent.auxiliary_client import _normalize_vision_provider | |||
There was a problem hiding this comment.
Please add an endpoint-resolution regression alongside this assertion: configure auxiliary.vision.provider: custom:moonshot and a matching custom_providers entry, then assert resolve_vision_provider_client() uses that custom base URL/key. The reported failure occurs after normalization when the vision path builds the client.
Summary
Test Plan