From 7e2866d9e90e2551a24e899de3cb0922916f7eae Mon Sep 17 00:00:00 2001 From: threebeanbags <244434555+threebeanbags@users.noreply.github.com> Date: Thu, 27 Nov 2025 20:46:01 -0800 Subject: [PATCH] fix(ui): prevent incorrect provider type suffix in update dialog The base engine names (e.g., 'openai', 'anthropic') are persisted correctly in the backend configuration. However, `ProviderGrid.tsx` was appending a `_compatible` suffix to the engine key before passing it to `CustomProviderForm`. `CustomProviderForm` expects the raw base engine name to correctly map it to the dropdown selection. Receiving the suffixed version caused the lookup to fail, defaulting the provider type to "OpenAI Compatible" and subsequently overwriting the correct configuration on save. This fix removes the unnecessary suffix, ensuring the form receives the correct engine key. This change is isolated to the custom provider configuration flow in the UI. Signed-off-by: threebeanbags <244434555+threebeanbags@users.noreply.github.com> --- ui/desktop/src/components/settings/providers/ProviderGrid.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/desktop/src/components/settings/providers/ProviderGrid.tsx b/ui/desktop/src/components/settings/providers/ProviderGrid.tsx index f970e9335678..5e9124fa0160 100644 --- a/ui/desktop/src/components/settings/providers/ProviderGrid.tsx +++ b/ui/desktop/src/components/settings/providers/ProviderGrid.tsx @@ -157,7 +157,7 @@ function ProviderCards({ }, [providers, isOnboarding, configureProviderViaModal, onProviderLaunch]); const initialData = editingProvider && { - engine: editingProvider.config.engine.toLowerCase() + '_compatible', + engine: editingProvider.config.engine.toLowerCase(), display_name: editingProvider.config.display_name, api_url: editingProvider.config.base_url, api_key: '',