fix(title_gen): honor auxiliary.title_generation.timeout config setting (#41812) - #41841
Closed
Elshayib wants to merge 1 commit into
Closed
fix(title_gen): honor auxiliary.title_generation.timeout config setting (#41812)#41841Elshayib wants to merge 1 commit into
Elshayib wants to merge 1 commit into
Conversation
The title generation path hardcoded a 30s timeout, ignoring the
auxiliary.title_generation.timeout config value. Thread the timeout
parameter through maybe_auto_title -> auto_title_session ->
generate_title, and read the config value in gateway/run.py via
_get_task_timeout('title_generation') so user-configured values
(e.g. 300s for slow local models) are respected.
Fixes #41812
Contributor
Author
|
CI failure is a pre-existing flaky test ( |
This was referenced Jul 1, 2026
Collaborator
|
Closing as superseded by #56322 (salvage of #41844) for #32729. Both fix the hardcoded title-generation timeout, but #41841 threads a timeout kwarg through auto_title_session/maybe_auto_title and re-computes _get_task_timeout('title_generation') in gateway/run.py — which duplicates the resolution call_llm already does internally when timeout=None. #41844 achieves the same result with the one-line default change and no gateway plumbing. Credit for the correct fix. Feel free to push back. |
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
Title generation ignored the
auxiliary.title_generation.timeoutconfig value, always using a hardcoded 30s default. Users with slow local models (e.g. Ollama on CPU) who setauxiliary.title_generation.timeout: 300still saw timeouts at 30s.Root Cause
The call chain
maybe_auto_title()→auto_title_session()→generate_title(timeout=30.0)→call_llm(timeout=30.0)never read the config value.call_llm()already supportstimeout=None→_get_task_timeout(task)which readsauxiliary.<task>.timeout, but the hardcoded30.0default overrode it.Changes
agent/title_generator.py: Changedgenerate_title()default fromtimeout: float = 30.0totimeout: Optional[float] = None. Threadtimeoutthroughmaybe_auto_title()andauto_title_session().gateway/run.py: Readauxiliary.title_generation.timeoutvia_get_task_timeout("title_generation")and pass it astimeouttomaybe_auto_title().tests/agent/test_title_generator.py: 5 new tests covering default-None behavior, explicit timeout forwarding through all three layers.Validation
Fixes #41812