diff --git a/src/core/config/ProviderSettingsManager.ts b/src/core/config/ProviderSettingsManager.ts index ed97f5803e..43017882fa 100644 --- a/src/core/config/ProviderSettingsManager.ts +++ b/src/core/config/ProviderSettingsManager.ts @@ -15,7 +15,7 @@ import { } from "@roo-code/types" import { TelemetryService } from "@roo-code/telemetry" -import { Agent, modes } from "../../shared/modes" +import { Mode, modes } from "../../shared/modes" import { buildApiHandler } from "../../api" // Type-safe model migrations mapping diff --git a/src/core/prompts/__tests__/add-custom-instructions.spec.ts b/src/core/prompts/__tests__/add-custom-instructions.spec.ts index 9e8645d587..5460e7aaf4 100644 --- a/src/core/prompts/__tests__/add-custom-instructions.spec.ts +++ b/src/core/prompts/__tests__/add-custom-instructions.spec.ts @@ -49,7 +49,7 @@ import { ModeConfig } from "@roo-code/types" import { SYSTEM_PROMPT } from "../system" import { McpHub } from "../../../services/mcp/McpHub" -import { defaultModeSlug, modes, Agent } from "../../../shared/modes" +import { defaultModeSlug, modes, Mode } from "../../../shared/modes" import "../../../utils/path" import { addCustomInstructions } from "../sections/custom-instructions" import { MultiSearchReplaceDiffStrategy } from "../../diff/strategies/multi-search-replace" diff --git a/src/core/prompts/__tests__/system-prompt.spec.ts b/src/core/prompts/__tests__/system-prompt.spec.ts index fec6db502f..2663d0ba29 100644 --- a/src/core/prompts/__tests__/system-prompt.spec.ts +++ b/src/core/prompts/__tests__/system-prompt.spec.ts @@ -49,7 +49,7 @@ import { ModeConfig } from "@roo-code/types" import { SYSTEM_PROMPT } from "../system" import { McpHub } from "../../../services/mcp/McpHub" -import { defaultModeSlug, modes, Agent } from "../../../shared/modes" +import { defaultModeSlug, modes, Mode } from "../../../shared/modes" import "../../../utils/path" import { addCustomInstructions } from "../sections/custom-instructions" import { MultiSearchReplaceDiffStrategy } from "../../diff/strategies/multi-search-replace" diff --git a/src/core/prompts/sections/__tests__/custom-system-prompt.spec.ts b/src/core/prompts/sections/__tests__/custom-system-prompt.spec.ts index aced21b34e..2de16bddcd 100644 --- a/src/core/prompts/sections/__tests__/custom-system-prompt.spec.ts +++ b/src/core/prompts/sections/__tests__/custom-system-prompt.spec.ts @@ -6,7 +6,7 @@ vi.mock("fs/promises") import type { Mock } from "vitest" import path from "path" import { readFile } from "fs/promises" -import type { Agent } from "../../../../shared/modes" // Type-only import +import type { Mode } from "../../../../shared/modes" // Type-only import import { loadSystemPromptFile, PromptVariables } from "../custom-system-prompt" // Cast the mocked readFile to the correct Mock type diff --git a/src/core/prompts/sections/custom-system-prompt.ts b/src/core/prompts/sections/custom-system-prompt.ts index f512f03abc..f401000bb5 100644 --- a/src/core/prompts/sections/custom-system-prompt.ts +++ b/src/core/prompts/sections/custom-system-prompt.ts @@ -1,6 +1,6 @@ import fs from "fs/promises" import path from "path" -import { Agent } from "../../../shared/modes" +import { Mode } from "../../../shared/modes" import { fileExistsAtPath } from "../../../utils/fs" export type PromptVariables = { diff --git a/src/core/prompts/system.ts b/src/core/prompts/system.ts index ae2ac4e44b..75b28bbb21 100644 --- a/src/core/prompts/system.ts +++ b/src/core/prompts/system.ts @@ -5,7 +5,7 @@ import type { ModeConfig, PromptComponent, CustomModePrompts, TodoItem } from "@ import type { SystemPromptSettings } from "./types" -import { Agent, modes, defaultModeSlug, getModeBySlug, getGroupName, getModeSelection } from "../../shared/modes" +import { Mode, modes, defaultModeSlug, getModeBySlug, getGroupName, getModeSelection } from "../../shared/modes" import { DiffStrategy } from "../../shared/tools" import { formatLanguage } from "../../shared/language" import { isEmpty } from "../../utils/object" diff --git a/src/core/prompts/tools/index.ts b/src/core/prompts/tools/index.ts index a01f6e6a61..a9e195c166 100644 --- a/src/core/prompts/tools/index.ts +++ b/src/core/prompts/tools/index.ts @@ -2,7 +2,7 @@ import type { ToolName, ModeConfig } from "@roo-code/types" import { TOOL_GROUPS, ALWAYS_AVAILABLE_TOOLS, DiffStrategy } from "../../../shared/tools" import { McpHub } from "../../../services/mcp/McpHub" -import { Agent, getModeConfig, isToolAllowedForMode, getGroupName } from "../../../shared/modes" +import { Mode, getModeConfig, isToolAllowedForMode, getGroupName } from "../../../shared/modes" import { ToolArgs } from "./types" import { getExecuteCommandDescription } from "./execute-command" diff --git a/src/core/tools/validateToolUse.ts b/src/core/tools/validateToolUse.ts index f47096c74c..a4ddf2ab77 100644 --- a/src/core/tools/validateToolUse.ts +++ b/src/core/tools/validateToolUse.ts @@ -1,7 +1,7 @@ import type { ToolName, ModeConfig } from "@roo-code/types" import { toolNames as validToolNames } from "@roo-code/types" -import { Agent, isToolAllowedForMode } from "../../shared/modes" +import { Mode, isToolAllowedForMode } from "../../shared/modes" /** * Checks if a tool name is a valid, known tool. diff --git a/src/core/webview/ClineProvider.ts b/src/core/webview/ClineProvider.ts index 66dfb20b60..94dec39512 100644 --- a/src/core/webview/ClineProvider.ts +++ b/src/core/webview/ClineProvider.ts @@ -53,7 +53,7 @@ import { findLast } from "../../shared/array" import { supportPrompt } from "../../shared/support-prompt" import { GlobalFileNames } from "../../shared/globalFileNames" import type { ExtensionMessage, ExtensionState, MarketplaceInstalledMetadata } from "../../shared/ExtensionMessage" -import { Agent, defaultModeSlug, getModeBySlug } from "../../shared/modes" +import { Mode, defaultModeSlug, getModeBySlug } from "../../shared/modes" import { experimentDefault } from "../../shared/experiments" import { formatLanguage } from "../../shared/language" import { WebviewMessage } from "../../shared/WebviewMessage" diff --git a/src/core/webview/webviewMessageHandler.ts b/src/core/webview/webviewMessageHandler.ts index 71ea534cb2..d1ef8d9f6a 100644 --- a/src/core/webview/webviewMessageHandler.ts +++ b/src/core/webview/webviewMessageHandler.ts @@ -53,7 +53,7 @@ import { getOpenAiModels } from "../../api/providers/openai" import { getVsCodeLmModels } from "../../api/providers/vscode-lm" import { openMention } from "../mentions" import { getWorkspacePath } from "../../utils/path" -import { Agent, defaultModeSlug } from "../../shared/modes" +import { Mode, defaultModeSlug } from "../../shared/modes" import { getModels, flushModels } from "../../api/providers/fetchers/modelCache" import { GetModelsOptions } from "../../shared/api" import { generateSystemPrompt } from "./generateSystemPrompt"