From f17b614d50d707eaae681ff23f0ca52554521ed3 Mon Sep 17 00:00:00 2001 From: Jaime Abril Date: Tue, 27 Jan 2026 00:04:00 +0100 Subject: [PATCH] fix: kiro-cli use arg input mode and disable wrap --- src/agents/cli-backends.ts | 4 ++-- src/commands/auth-choice.model-check.ts | 8 +++++--- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/agents/cli-backends.ts b/src/agents/cli-backends.ts index 747873d65..76ec76fa0 100644 --- a/src/agents/cli-backends.ts +++ b/src/agents/cli-backends.ts @@ -88,9 +88,9 @@ const DEFAULT_CODEX_BACKEND: CliBackendConfig = { const DEFAULT_KIRO_BACKEND: CliBackendConfig = { command: "kiro-cli", - args: ["chat", "--no-interactive"], + args: ["chat", "--no-interactive", "--wrap", "never"], output: "text", - input: "stdin", + input: "arg", modelArg: "--model", modelAliases: KIRO_MODEL_ALIASES, sessionMode: "none", diff --git a/src/commands/auth-choice.model-check.ts b/src/commands/auth-choice.model-check.ts index 74fe003ee..9133eec8d 100644 --- a/src/commands/auth-choice.model-check.ts +++ b/src/commands/auth-choice.model-check.ts @@ -3,7 +3,7 @@ import { ensureAuthProfileStore, listProfilesForProvider } from "../agents/auth- import { DEFAULT_MODEL, DEFAULT_PROVIDER } from "../agents/defaults.js"; import { getCustomProviderApiKey, resolveEnvApiKey } from "../agents/model-auth.js"; import { loadModelCatalog } from "../agents/model-catalog.js"; -import { resolveConfiguredModelRef } from "../agents/model-selection.js"; +import { isCliProvider, resolveConfiguredModelRef } from "../agents/model-selection.js"; import type { ClawdbotConfig } from "../config/config.js"; import type { WizardPrompter } from "../wizard/prompts.js"; import { OPENAI_CODEX_DEFAULT_MODEL } from "./openai-codex-model-default.js"; @@ -44,7 +44,8 @@ export async function warnIfModelConfigLooksOff( config: configWithModel, useCache: false, }); - if (catalog.length > 0) { + // CLI backends (claude-cli, codex-cli, kiro-cli) aren't in the catalog - skip the check for them + if (catalog.length > 0 && !isCliProvider(ref.provider, configWithModel)) { const known = catalog.some( (entry) => entry.provider === ref.provider && entry.id === ref.model, ); @@ -59,7 +60,8 @@ export async function warnIfModelConfigLooksOff( const hasProfile = listProfilesForProvider(store, ref.provider).length > 0; const envKey = resolveEnvApiKey(ref.provider); const customKey = getCustomProviderApiKey(config, ref.provider); - if (!hasProfile && !envKey && !customKey) { + // CLI backends handle auth differently - skip the auth check for them + if (!isCliProvider(ref.provider, configWithModel) && !hasProfile && !envKey && !customKey) { warnings.push( `No auth configured for provider "${ref.provider}". The agent may fail until credentials are added.`, );