Skip to content

fix(setup): remove saved custom provider from migrated config - #63287

Closed
ajzrva-sys wants to merge 1 commit into
NousResearch:mainfrom
ajzrva-sys:fix/remove-custom-provider
Closed

fix(setup): remove saved custom provider from migrated config#63287
ajzrva-sys wants to merge 1 commit into
NousResearch:mainfrom
ajzrva-sys:fix/remove-custom-provider

Conversation

@ajzrva-sys

Copy link
Copy Markdown
Contributor

Fixes removing a saved custom provider in hermes setup model.

Hermes stores named custom endpoints in two formats:

  • Legacy custom_providers: list
  • Migrated providers: dict (after config migration)

The remove flow previously only edited custom_providers, so migrated providers could not be removed — the menu would show 'No custom providers configured' even when entries existed in providers:.

This PR:

  • Lists custom providers from both custom_providers and providers
  • Removes the selected entry from the correct section
  • Adds regression tests for both paths

Fixes #5525

Support both legacy custom_providers list and migrated providers dict
when listing and removing saved custom endpoints.

Previously _remove_custom_provider only read from custom_providers, so
providers that had been migrated to the providers: dict could not be
removed — the menu would show 'No custom providers configured' even
when entries existed.

Now enumerates entries from both sections and removes from the
correct source.

Fixes NousResearch#5525
@ajzrva-sys

Copy link
Copy Markdown
Contributor Author

Closing in favor of #14360 which takes the same approach (get_compatible_custom_providers + dual-schema removal) and was filed first. Added my dedup test case as a suggestion there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]:Remove a saved custom provider does not work.

1 participant