Repository navigation
fix(settings): test the LLM address and model on screen, not only the saved ones - #539
Merged
Merged
Conversation
… saved ones The Test button in Settings → LLM provider tested the saved settings, so a new address or model typed but not saved was never tried. The test route now takes base_url, model and api_key; the saved key goes only to the saved address. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BHjm8NXrMmJrZH8D71s4MN
Ported from #400 so this PR's clicks survey passes while that lands: the survey hung after its first chat answer when the garbage collector closed an abandoned streamed answer mid-query on the thread holding the one embedded connection. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BHjm8NXrMmJrZH8D71s4MN
Owner
Author
|
Clicks and keystrokes per feature failed on 644d9ef: the computer survey hung after Generated by Claude Code |
adeelahmad
pushed a commit
that referenced
this pull request
Oct 18, 2026
Main carries its own fix for the frozen server (#539): a thread inside a query is given its connection again. Kept for the embedded engine, which has the one connection; against a server the inner query takes another connection from the pool, because the SDK sends on a server connection under a lock the same thread cannot take twice, so sharing it would hang there too. The duplicate test goes; a server-side test joins main's. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AjJqXgjj1cNdKGRQbX5frb
22 of 23 tasks
adeelahmad
added a commit
that referenced
this pull request
Oct 18, 2026
An automation's If can look back over the stream with `seen`, and a running automation's If, its graph's condition, filter and switch nodes and a trigger's `where` get the run's clock, time zone and one State per run, so `changed` works. Also fixes the server freeze behind the failing Clicks check: a query made inside another on the same thread shares the embedded engine's connection (as #539) and takes another connection against a server, whose SDK lock the same thread cannot take twice. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AjJqXgjj1cNdKGRQbX5frb
Merged
20 of 23 tasks
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.
Description
Before: Test in Settings → LLM provider always tested the saved settings. A new address or model typed but not saved was never tried, so the test reported the old server's error (for example "can't reach the LLM server at http://10.0.20.11:1434/v1: Connection reset by peer").
After: Test tries the address, model and key on screen, saved or not. The saved key goes only to the saved address, so a new address is tested with the key typed for it, never the stored one.
How:
POST /api/v1/settings/llm/testtakes an optionalLlmTrybody (base_url,model,api_key); with no body it tests what is saved, as before (the health page and the setup wizard still call it that way).llm.trying()lays typed values over the saved ones and drops the saved key and key variable when the address changes. Settings sends the form's values.Motivation and Context
Adeel's connection test failed against his local model server because the button read the saved values instead of what was typed.
Types of changes
Checklist:
test_llm_test_tries_what_is_typed,test_llm_trying_keeps_the_saved_key_at_the_saved_address, and a Settings jest case.docs/configuration.md.Done questions (AGENTS.md)
make openapi) updated./settings/files/test, which already takes unsaved values.Generated by Claude Code