Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 6 additions & 7 deletions open-sse/executors/base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -264,13 +264,12 @@ export class BaseExecutor {
const transformedBody = this.transformRequest(model, body, stream, credentials);

try {
// For non-streaming requests, apply a fetch timeout to prevent stalled connections.
// Streaming requests skip the timeout — they use stream idle detection instead.
const timeoutSignal = !stream ? AbortSignal.timeout(FETCH_TIMEOUT_MS) : null;
const combinedSignal =
signal && timeoutSignal
? mergeAbortSignals(signal, timeoutSignal)
: signal || timeoutSignal;
// Apply timeout to all requests. Non-streaming requests need this to prevent
// stalled connections. Streaming requests also need it for the initial fetch() call
// to prevent hanging on unresponsive providers (e.g. 300s TCP default timeout — #769).
// Stream idle detection (STREAM_IDLE_TIMEOUT_MS) handles stalls after data starts flowing.
const timeoutSignal = AbortSignal.timeout(FETCH_TIMEOUT_MS);
const combinedSignal = signal ? mergeAbortSignals(signal, timeoutSignal) : timeoutSignal;
Comment on lines +267 to +272

Copilot AI Mar 29, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AbortSignal.timeout(FETCH_TIMEOUT_MS) applies to the entire streaming request lifetime, not just the initial connection. With signal always provided in streaming mode (via streamController.signal), this will abort long-running streams after FETCH_TIMEOUT_MS even if data is flowing, which conflicts with the comment/PR intent of only protecting the initial fetch() hang. If the goal is only an initial connect/headers timeout, use a separate AbortController timer that is cleared once the response is established (or once the first chunk arrives), and rely on STREAM_IDLE_TIMEOUT_MS thereafter.

Copilot uses AI. Check for mistakes.

Comment on lines +272 to 273

Copilot AI Mar 29, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When signal is present, mergeAbortSignals(signal, timeoutSignal) aborts via a new AbortController without preserving the abort reason. If the timeout signal fires, the merged signal will typically surface as an AbortError rather than a TimeoutError, so the err.name === "TimeoutError" branch won’t run and timeouts may be misclassified. Consider forwarding the abort reason from the triggering signal (e.g., abort with primary.reason/secondary.reason) so timeout errors remain detectable/loggable.

Suggested change
const combinedSignal = signal ? mergeAbortSignals(signal, timeoutSignal) : timeoutSignal;
let combinedSignal: AbortSignal | undefined;
if (signal) {
const controller = new AbortController();
const forwardAbort = (src: AbortSignal) => {
if (src.aborted) {
controller.abort(src.reason);
} else {
src.addEventListener(
"abort",
() => controller.abort(src.reason),
{ once: true },
);
}
};
forwardAbort(signal);
forwardAbort(timeoutSignal);
combinedSignal = controller.signal;
} else {
combinedSignal = timeoutSignal;
}

Copilot uses AI. Check for mistakes.
// Apply CLI fingerprint ordering if enabled for this provider
let finalHeaders = headers;
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/ar.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "محرر كود المؤشر AI",
"continue": "تابع مساعد الذكاء الاصطناعي",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/bg.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Cursor AI Code Editor",
"continue": "Продължете AI Assistant",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/cs.json
Original file line number Diff line number Diff line change
Expand Up @@ -643,7 +643,9 @@
"cursor": "Cursor AI Code Editor",
"continue": "Continue AI asistent",
"opencode": "OpenCode AI coding agent (Terminál)",
"kiro": "Amazon Kiro – AI poháněné IDE"
"kiro": "Amazon Kiro – AI poháněné IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/da.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Cursor AI Code Editor",
"continue": "Fortsæt AI Assistant",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/de.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Cursor-KI-Code-Editor",
"continue": "Weiter AI Assistant",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -648,7 +648,9 @@
"cursor": "Cursor AI Code Editor",
"continue": "Continue AI Assistant",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
Comment on lines +651 to +653

Copilot AI Mar 29, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cliTools.toolUseCases still has no windsurf entry (e.g. en.json has copilot but not windsurf). Since the UI calls t("toolUseCases.<toolId>") for every tool, this will continue to emit MISSING_MESSAGE: cliTools.toolUseCases.windsurf in the console. Add a toolUseCases.windsurf string to all locale files (or change the UI to not call t() for optional keys).

Copilot uses AI. Check for mistakes.
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/es.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Editor de código AI del cursor",
"continue": "Continuar Asistente de IA",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/fi.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Cursor AI Code Editor",
"continue": "Jatka AI Assistantia",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/fr.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Éditeur de code AI du curseur",
"continue": "Continuer l'Assistant IA",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/he.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "עורך קוד AI של הסמן",
"continue": "המשך עוזר AI",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/hi.json
Original file line number Diff line number Diff line change
Expand Up @@ -489,7 +489,9 @@
"cursor": "कर्सर एआई कोड संपादक",
"continue": "एआई असिस्टेंट जारी रखें",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/hu.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Kurzor AI kódszerkesztő",
"continue": "Az AI-asszisztens folytatása",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/id.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Editor Kode AI Kursor",
"continue": "Lanjutkan Asisten AI",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/in.json
Original file line number Diff line number Diff line change
Expand Up @@ -643,7 +643,9 @@
"cursor": "कर्सर एआई कोड संपादक",
"continue": "एआई असिस्टेंट जारी रखें",
"opencode": "ओपनकोड एआई कोडिंग एजेंट (टर्मिनल)",
"kiro": "अमेज़ॅन किरो - एआई-संचालित आईडीई"
"kiro": "अमेज़ॅन किरो - एआई-संचालित आईडीई",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/it.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Editor del codice AI del cursore",
"continue": "Continua Assistente AI",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/ja.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "カーソルAIコードエディター",
"continue": "AIアシスタントを続ける",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/ko.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "커서 AI 코드 편집기",
"continue": "AI 어시스턴트 계속하기",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/ms.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Editor Kod AI Kursor",
"continue": "Teruskan AI Assistant",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/nl.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Cursor AI-code-editor",
"continue": "Ga door met AI-assistent",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/no.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Cursor AI Code Editor",
"continue": "Fortsett AI Assistant",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/phi.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Cursor AI Code Editor",
"continue": "Ipagpatuloy ang AI Assistant",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/pl.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Edytor kodu AI kursora",
"continue": "Kontynuuj Asystenta AI",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/pt-BR.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Editor de código com IA Cursor",
"continue": "Assistente de IA Continue",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — IDE com IA",
"windsurf": "Windsurf — Editor de Código com IA",
"copilot": "GitHub Copilot — Assistente de IA"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/pt.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Editor de código do cursor AI",
"continue": "Continuar Assistente de IA",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/ro.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Cursor AI Code Editor",
"continue": "Continuați Asistentul AI",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/ru.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Редактор кода курсора AI",
"continue": "Продолжить AI-помощник",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/sk.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Editor kódu AI kurzora",
"continue": "Pokračovať v Asistentovi AI",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/sv.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Cursor AI Code Editor",
"continue": "Fortsätt AI Assistant",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/th.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "ตัวแก้ไขรหัสเคอร์เซอร์ AI",
"continue": "ดำเนินการต่อผู้ช่วย AI",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/tr.json
Original file line number Diff line number Diff line change
Expand Up @@ -641,7 +641,9 @@
"cursor": "Cursor AI Kod Düzenleyici",
"continue": "Continue AI Asistanı",
"opencode": "OpenCode AI kodlama ajanı (Terminal)",
"kiro": "Amazon Kiro - AI destekli IDE"
"kiro": "Amazon Kiro - AI destekli IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/uk-UA.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Редактор коду Cursor AI",
"continue": "Продовжити AI Assistant",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/vi.json
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@
"cursor": "Trình chỉnh sửa mã AI con trỏ",
"continue": "Tiếp tục Trợ lý AI",
"opencode": "OpenCode AI coding agent (Terminal)",
"kiro": "Amazon Kiro — AI-powered IDE"
"kiro": "Amazon Kiro — AI-powered IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/messages/zh-CN.json
Original file line number Diff line number Diff line change
Expand Up @@ -627,7 +627,9 @@
"cursor": "Cursor AI 代码编辑器",
"continue": "继续AI助手",
"opencode": "OpenCode AI 编码智能体(终端)",
"kiro": "Amazon Kiro - AI 驱动 IDE"
"kiro": "Amazon Kiro - AI 驱动 IDE",
"windsurf": "Windsurf AI Code Editor",
"copilot": "GitHub Copilot AI Assistant"
},
"guides": {
"cursor": {
Expand Down
Loading