qwen-code/packages/cli/src
Nothing Chan 0a54652e07
fix(core): configurable vision bridge timeout + retry with fresh budget (#6541)
* fix(core): configurable vision bridge timeout + retry with fresh budget

The vision bridge capped image transcription at a hardcoded 30s. On a
slow or proxied vision endpoint one latency spike permanently lost the
image: the retry inside the side query shared the same abort signal, so
a second attempt inherited whatever seconds were left of the first
attempt's budget.

Add a visionBridgeTimeoutMs setting (per attempt; unset keeps 30s,
non-positive values are ignored) and retry a timed-out attempt once at
the bridge level with a freshly created timeout signal. Non-timeout
failures still fail immediately, and user cancellation is still
reported as skipped.

Fixes #6524

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* fix(core): harden visionBridgeTimeoutMs against invalid timer values

Maintainer E2E review found that fractional or out-of-range values such as 30000.5 and 4294967296 could pass the old number-typed config path and Config's Number.isFinite && > 0 guard. Node rejects fractional AbortSignal.timeout values with RangeError and can degrade oversized timer values to a 1ms timeout, which made image turns fail before any model request.

Tighten the Config guard to positive integers within the supported 32-bit timer ceiling, make visionBridgeTimeoutMs a bounded integer setting so /config and the generated JSON schema reject bad values up front, and move AbortSignal.timeout/any creation inside the bridge try block so any future bad value becomes a safe failure result instead of an escaped rejection. Also mark the setting requiresRestart because it is read once in the Config constructor.

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

---------

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-07-08 23:24:39 +00:00
..
acp-integration fix(session): detect and mark broken history chains instead of silently truncating (#6502) 2026-07-08 16:02:58 +00:00
commands feat(channels): add dmPolicy config to disable private/DM messages (#6521) 2026-07-08 12:01:10 +00:00
config fix(core): configurable vision bridge timeout + retry with fresh budget (#6541) 2026-07-08 23:24:39 +00:00
core perf(cli): defer startup prefetch tasks (#6303) 2026-07-07 15:31:55 +00:00
dualOutput fix(dual-output): prevent FIFO blocking on startup when no reader connected (#4894) 2026-06-15 06:04:06 +08:00
export feat(vscode-companion): support /export session command (#2592) 2026-04-24 17:55:26 +08:00
i18n fix(session): detect and mark broken history chains instead of silently truncating (#6502) 2026-07-08 16:02:58 +00:00
nonInteractive feat(core): model fallback chain — auto-switch to backup models on overload (#6273) 2026-07-05 12:29:10 +00:00
patches adh/bugfix/1563 (#4822) 2025-07-25 16:39:37 +00:00
remoteInput fix(cli): preserve partial remote input JSONL records (#6317) 2026-07-04 22:19:58 +00:00
serve feat(cli): Add session owner index for workspace runtimes (#6540) 2026-07-08 22:35:53 +00:00
services feat: extension file reload — watch for plugin changes and hot-reload runtime (#6347) 2026-07-08 11:16:21 +00:00
startup fix(cli): clean up IDE client after deferred timeout (#6509) 2026-07-08 07:43:59 +00:00
test-utils feat(cli): add --project and --global flags to /model for per-project model persistence (#6060) 2026-07-07 04:49:36 +00:00
ui fix(core): configurable vision bridge timeout + retry with fresh budget (#6541) 2026-07-08 23:24:39 +00:00
utils fix(core): configurable vision bridge timeout + retry with fresh budget (#6541) 2026-07-08 23:24:39 +00:00
cli.test.ts fix(cli): add bootstrap fast paths (#6188) 2026-07-02 22:28:11 +00:00
cli.ts feat(core): model fallback chain — auto-switch to backup models on overload (#6273) 2026-07-05 12:29:10 +00:00
gemini.test.tsx feat: extension file reload — watch for plugin changes and hot-reload runtime (#6347) 2026-07-08 11:16:21 +00:00
gemini.tsx feat: extension file reload — watch for plugin changes and hot-reload runtime (#6347) 2026-07-08 11:16:21 +00:00
nonInteractiveCli.test.ts fix(core): give Stop-hook continuations a fresh per-turn tool-call budget; make the cap configurable (#6238) 2026-07-04 02:36:59 +00:00
nonInteractiveCli.ts feat(core): model fallback chain — auto-switch to backup models on overload (#6273) 2026-07-05 12:29:10 +00:00
nonInteractiveCliCommands.test.ts feat(cli): support stacked slash-skill invocations (#6361) 2026-07-07 06:38:04 +00:00
nonInteractiveCliCommands.ts feat(cli): support stacked slash-skill invocations (#6361) 2026-07-07 06:38:04 +00:00
validateNonInterActiveAuth.test.ts feat(auth): discontinue Qwen OAuth free tier (2026-04-15 cutoff) (#3291) 2026-04-15 22:30:20 +08:00
validateNonInterActiveAuth.ts Merge branch 'main' into feat/debug-logging-refactor 2026-02-01 20:47:38 +08:00