@@ -1733,6 +1733,110 @@ export class ClineProvider
17331733 includeDiagnosticMessages : stateValues . includeDiagnosticMessages ?? DEFAULT_INCLUDE_DIAGNOSTIC_MESSAGES ,
17341734 maxDiagnosticMessages : stateValues . maxDiagnosticMessages ?? DEFAULT_MAX_DIAGNOSTIC_MESSAGES ,
17351735 }
1736+
1737+ // Log diagnostic settings retrieval
1738+ DiagnosticDebugLogger . getInstance ( ) . log ( "ClineProvider.getState" , "Retrieved diagnostic settings from state" , {
1739+ includeDiagnosticMessages : stateValues . includeDiagnosticMessages ,
1740+ maxDiagnosticMessages : stateValues . maxDiagnosticMessages ,
1741+ defaultsApplied : {
1742+ includeDiagnosticMessages : stateValues . includeDiagnosticMessages === undefined ,
1743+ maxDiagnosticMessages : stateValues . maxDiagnosticMessages === undefined ,
1744+ } ,
1745+ } )
1746+
1747+ // Return the same structure as before
1748+ return {
1749+ apiConfiguration : providerSettings ,
1750+ lastShownAnnouncementId : stateValues . lastShownAnnouncementId ,
1751+ customInstructions : stateValues . customInstructions ,
1752+ apiModelId : stateValues . apiModelId ,
1753+ alwaysAllowReadOnly : stateValues . alwaysAllowReadOnly ?? false ,
1754+ alwaysAllowReadOnlyOutsideWorkspace : stateValues . alwaysAllowReadOnlyOutsideWorkspace ?? false ,
1755+ alwaysAllowWrite : stateValues . alwaysAllowWrite ?? false ,
1756+ alwaysAllowWriteOutsideWorkspace : stateValues . alwaysAllowWriteOutsideWorkspace ?? false ,
1757+ alwaysAllowWriteProtected : stateValues . alwaysAllowWriteProtected ?? false ,
1758+ alwaysAllowExecute : stateValues . alwaysAllowExecute ?? false ,
1759+ alwaysAllowBrowser : stateValues . alwaysAllowBrowser ?? false ,
1760+ alwaysAllowMcp : stateValues . alwaysAllowMcp ?? false ,
1761+ alwaysAllowModeSwitch : stateValues . alwaysAllowModeSwitch ?? false ,
1762+ alwaysAllowSubtasks : stateValues . alwaysAllowSubtasks ?? false ,
1763+ alwaysAllowFollowupQuestions : stateValues . alwaysAllowFollowupQuestions ?? false ,
1764+ alwaysAllowUpdateTodoList : stateValues . alwaysAllowUpdateTodoList ?? false ,
1765+ followupAutoApproveTimeoutMs : stateValues . followupAutoApproveTimeoutMs ?? 60000 ,
1766+ allowedMaxRequests : stateValues . allowedMaxRequests ,
1767+ autoCondenseContext : stateValues . autoCondenseContext ?? true ,
1768+ autoCondenseContextPercent : stateValues . autoCondenseContextPercent ?? 100 ,
1769+ taskHistory : stateValues . taskHistory ,
1770+ allowedCommands : stateValues . allowedCommands ,
1771+ soundEnabled : stateValues . soundEnabled ?? false ,
1772+ ttsEnabled : stateValues . ttsEnabled ?? false ,
1773+ ttsSpeed : stateValues . ttsSpeed ?? 1.0 ,
1774+ diffEnabled : stateValues . diffEnabled ?? true ,
1775+ enableCheckpoints : stateValues . enableCheckpoints ?? true ,
1776+ soundVolume : stateValues . soundVolume ,
1777+ browserViewportSize : stateValues . browserViewportSize ?? "900x600" ,
1778+ screenshotQuality : stateValues . screenshotQuality ?? 75 ,
1779+ remoteBrowserHost : stateValues . remoteBrowserHost ,
1780+ remoteBrowserEnabled : stateValues . remoteBrowserEnabled ?? false ,
1781+ cachedChromeHostUrl : stateValues . cachedChromeHostUrl as string | undefined ,
1782+ fuzzyMatchThreshold : stateValues . fuzzyMatchThreshold ?? 1.0 ,
1783+ writeDelayMs : stateValues . writeDelayMs ?? 1000 ,
1784+ terminalOutputLineLimit : stateValues . terminalOutputLineLimit ?? 500 ,
1785+ terminalShellIntegrationTimeout :
1786+ stateValues . terminalShellIntegrationTimeout ?? Terminal . defaultShellIntegrationTimeout ,
1787+ terminalShellIntegrationDisabled : stateValues . terminalShellIntegrationDisabled ?? false ,
1788+ terminalCommandDelay : stateValues . terminalCommandDelay ?? 0 ,
1789+ terminalPowershellCounter : stateValues . terminalPowershellCounter ?? false ,
1790+ terminalZshClearEolMark : stateValues . terminalZshClearEolMark ?? true ,
1791+ terminalZshOhMy : stateValues . terminalZshOhMy ?? false ,
1792+ terminalZshP10k : stateValues . terminalZshP10k ?? false ,
1793+ terminalZdotdir : stateValues . terminalZdotdir ?? false ,
1794+ terminalCompressProgressBar : stateValues . terminalCompressProgressBar ?? true ,
1795+ mode : stateValues . mode ?? defaultModeSlug ,
1796+ language : stateValues . language ?? formatLanguage ( vscode . env . language ) ,
1797+ mcpEnabled : stateValues . mcpEnabled ?? true ,
1798+ enableMcpServerCreation : stateValues . enableMcpServerCreation ?? true ,
1799+ alwaysApproveResubmit : stateValues . alwaysApproveResubmit ?? false ,
1800+ requestDelaySeconds : Math . max ( 5 , stateValues . requestDelaySeconds ?? 10 ) ,
1801+ currentApiConfigName : stateValues . currentApiConfigName ?? "default" ,
1802+ listApiConfigMeta : stateValues . listApiConfigMeta ?? [ ] ,
1803+ pinnedApiConfigs : stateValues . pinnedApiConfigs ?? { } ,
1804+ modeApiConfigs : stateValues . modeApiConfigs ?? ( { } as Record < Mode , string > ) ,
1805+ customModePrompts : stateValues . customModePrompts ?? { } ,
1806+ customSupportPrompts : stateValues . customSupportPrompts ?? { } ,
1807+ enhancementApiConfigId : stateValues . enhancementApiConfigId ,
1808+ experiments : stateValues . experiments ?? experimentDefault ,
1809+ autoApprovalEnabled : stateValues . autoApprovalEnabled ?? false ,
1810+ customModes,
1811+ maxOpenTabsContext : stateValues . maxOpenTabsContext ?? 20 ,
1812+ maxWorkspaceFiles : stateValues . maxWorkspaceFiles ?? 200 ,
1813+ openRouterUseMiddleOutTransform : stateValues . openRouterUseMiddleOutTransform ?? true ,
1814+ browserToolEnabled : stateValues . browserToolEnabled ?? true ,
1815+ telemetrySetting : stateValues . telemetrySetting || "unset" ,
1816+ showRooIgnoredFiles : stateValues . showRooIgnoredFiles ?? true ,
1817+ maxReadFileLine : stateValues . maxReadFileLine ?? - 1 ,
1818+ maxConcurrentFileReads : stateValues . maxConcurrentFileReads ?? 5 ,
1819+ historyPreviewCollapsed : stateValues . historyPreviewCollapsed ?? false ,
1820+ cloudUserInfo,
1821+ cloudIsAuthenticated,
1822+ sharingEnabled,
1823+ organizationAllowList,
1824+ // Explicitly add condensing settings
1825+ condensingApiConfigId : stateValues . condensingApiConfigId ,
1826+ customCondensingPrompt : stateValues . customCondensingPrompt ,
1827+ codebaseIndexModels : stateValues . codebaseIndexModels ?? EMBEDDING_MODEL_PROFILES ,
1828+ codebaseIndexConfig : stateValues . codebaseIndexConfig ?? {
1829+ codebaseIndexEnabled : true ,
1830+ codebaseIndexQdrantUrl : "http://localhost:6333" ,
1831+ codebaseIndexEmbedderProvider : "openai" ,
1832+ codebaseIndexEmbedderBaseUrl : "" ,
1833+ codebaseIndexEmbedderModelId : "" ,
1834+ } ,
1835+ profileThresholds : stateValues . profileThresholds ?? { } ,
1836+ // Add diagnostic message settings
1837+ includeDiagnosticMessages : stateValues . includeDiagnosticMessages ?? DEFAULT_INCLUDE_DIAGNOSTIC_MESSAGES ,
1838+ maxDiagnosticMessages : stateValues . maxDiagnosticMessages ?? DEFAULT_MAX_DIAGNOSTIC_MESSAGES ,
1839+ }
17361840 }
17371841
17381842 async updateTaskHistory ( item : HistoryItem ) : Promise < HistoryItem [ ] > {
0 commit comments