fix(ui): prevent OpenAI API Host fallback when saving other fields#7246
Closed
bavadim wants to merge 3 commits intoblock:mainfrom
Closed
fix(ui): prevent OpenAI API Host fallback when saving other fields#7246bavadim wants to merge 3 commits intoblock:mainfrom
bavadim wants to merge 3 commits intoblock:mainfrom
Conversation
Signed-off-by: bavadim <bavadim@gmail.com>
Signed-off-by: bavadim <bavadim@gmail.com>
f5ab842 to
1e5367a
Compare
5 tasks
Collaborator
|
thanks! somebody else also fixed this. since they have the DCO check, going to merge that one, but appreciate your efforts! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes a UI bug in OpenAI provider settings where saving changes to a non-host field can cause the effective
API Hostto fall back to default (https://api.openai.com) even whenAPI Hostwas not edited.The UI can still display the previously entered host text, so the regression is easy to miss.
Type of Change
AI Assistance
Testing
ui/desktop/src/components/settings/providers/modal/subcomponents/handlers/DefaultSubmitHandler.test.tsOPENAI_API_KEYwithout editingOPENAI_HOST, and assert host does not revert to default.main(host falls back to default).Related Issues
Relates to #7245
Discussion: #7245
Screenshots/Demos (for UX changes)
Before:
Changing another OpenAI field and saving could make effective
API Hostrevert to default while UI still showed old host text.After:
Saving changes to non-host fields preserves previously configured
API Host.