Skip to content

fix(model-switch): mark bare custom provider as current#28860

Merged
teknium1 merged 1 commit into
mainfrom
hermes/hermes-46103ba9
May 19, 2026
Merged

fix(model-switch): mark bare custom provider as current#28860
teknium1 merged 1 commit into
mainfrom
hermes/hermes-46103ba9

Conversation

@teknium1

Copy link
Copy Markdown
Contributor

Salvage of #23559 by @LeonSGP43 onto current main.

Summary

Fixes hermes model picker listing the wrong custom provider as current when the active provider slug is the bare custom bucket. The picker now also matches by current base_url, so the correct custom endpoint is marked is_current.

Fixes #20811.

Changes

  • hermes_cli/model_switch.py: is_current falls back to comparing current_base_url against the group's normalized URL when the slug match fails (_grp_url_norm is already computed in the same function).
  • tests/hermes_cli/test_model_switch_custom_providers.py: tightened the existing bare-custom regression test to also assert is_current is True.

Validation

tests/hermes_cli/test_model_switch_custom_providers.py: 18/18 passing.

Original PR #23559 cherry-picked cleanly (981 commits stale, no conflicts). LeonSGP43's authorship preserved.

@teknium1 teknium1 merged commit ebe0b77 into main May 19, 2026
16 of 17 checks passed
@teknium1 teknium1 deleted the hermes/hermes-46103ba9 branch May 19, 2026 17:57
@github-actions

Copy link
Copy Markdown
Contributor

🔎 Lint report: hermes/hermes-46103ba9 vs origin/main

ruff

Total: 0 on HEAD, 0 on base (➖ 0)

🆕 New issues: none

✅ Fixed issues: none

Unchanged: 0 pre-existing issues carried over.

ty (type checker)

Total: 8963 on HEAD, 8963 on base (➖ 0)

🆕 New issues: none

✅ Fixed issues: none

Unchanged: 4719 pre-existing issues carried over.

Diagnostics are surfaced as warnings — this check never fails the build.

@alt-glitch alt-glitch added type/bug Something isn't working comp/cli CLI entry point, hermes_cli/, setup wizard P2 Medium — degraded but workaround exists labels May 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/cli CLI entry point, hermes_cli/, setup wizard P2 Medium — degraded but workaround exists type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Fix: is_current check fails for bare 'custom' provider in custom endpoints section

3 participants