Skip to content

Fix/honor per engine timeout#182

Merged
cukas merged 2 commits into
mainfrom
fix/honor-per-engine-timeout
Jun 9, 2026
Merged

Fix/honor per engine timeout#182
cukas merged 2 commits into
mainfrom
fix/honor-per-engine-timeout

Conversation

@cukas

@cukas cukas commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

No description provided.

cukas and others added 2 commits June 9, 2026 15:38
Slow coding-plan engines (e.g. zai-coding-plan-glm-5.1) declare their own
EngineDefinition.timeout (180s), but dispatch only used the generic command
default (brainstorm/tribunal/council = 120s), so a slow engine got cut off
mid-answer and lost its slot ("Failed to respond: Request timed out").

Raise options.timeout to the engine's declared timeout when it's higher,
at the single dispatch chokepoint — so all exec orchestration honors it.
Precedent: forge stages.kern:106 already reads engine.timeout.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…utation

Addresses agon review of the prior commit (4/4 reviewers):
- Coverage: the timeout override was only in dispatch(); dispatchStream,
  dispatchAgent, dispatchAgentStream still cut slow engines at the command
  default. Extract a withEngineTimeout() helper and call it from all four.
- No mutation: helper returns a NEW options object ({...options, timeout})
  instead of mutating the caller's DispatchOptions (safe under reuse/retry).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@cukas cukas merged commit a565ee3 into main Jun 9, 2026
2 checks passed
@cukas cukas deleted the fix/honor-per-engine-timeout branch June 9, 2026 14:48
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.

1 participant