{"record":{"id":"c54f66bb12bf9df7","repo":"gitbutlerapp/gitbutler","slug":"please-check-ollama-configuration-endpoint-endp","errorCode":null,"errorMessage":"Please check Ollama configuration: endpoint=${endpoint}, model=${model}","messagePattern":"Please check Ollama configuration: endpoint=(.+?), model=(.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"apps/desktop/src/components/settings/AiCredentialCheck.svelte","lineNumber":85,"sourceCode":"\t\t\tisUsingButlerAPI = await aiService.usingGitButlerAPI();\n\t\t\tdebugInfo += `, Using GB API: ${isUsingButlerAPI}`;\n\n\t\t\t// Check if configuration is valid\n\t\t\tconst isConfigValid = await aiService.validateConfiguration();\n\t\t\tdebugInfo += `, Config valid: ${isConfigValid}`;\n\n\t\t\tif (!isConfigValid) {\n\t\t\t\tif (modelKind === ModelKind.OpenAI || modelKind === ModelKind.Anthropic) {\n\t\t\t\t\tif (isUsingButlerAPI && !userService.user) {\n\t\t\t\t\t\tthrow new Error(\"Please sign in to use GitButler's AI API\");\n\t\t\t\t\t} else {\n\t\t\t\t\t\tthrow new Error(\"Please provide a valid API key for your selected AI service\");\n\t\t\t\t\t}\n\t\t\t\t} else if (modelKind === ModelKind.Ollama) {\n\t\t\t\t\t// Get Ollama configuration for more detailed error\n\t\t\t\t\tconst endpoint = await aiService.getOllamaEndpoint();\n\t\t\t\t\tconst model = await aiService.getOllamaModelName();\n\t\t\t\t\tthrow new Error(\n\t\t\t\t\t\t`Please check Ollama configuration: endpoint=${endpoint}, model=${model}`,\n\t\t\t\t\t);\n\t\t\t\t} else if (modelKind === ModelKind.LMStudio) {\n\t\t\t\t\t// Get LM Studio configuration for more detailed error\n\t\t\t\t\tconst endpoint = await aiService.getLMStudioEndpoint();\n\t\t\t\t\tthrow new Error(`Please check LM Studio configuration: endpoint=${endpoint}`);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tdebugInfo += `, Testing commit message generation`;\n\n\t\t\t// Set a timeout to fail if the streaming doesn't start or complete\n\t\t\ttestTimeout = setTimeout(() => {\n\t\t\t\tif (testing) {\n\t\t\t\t\tconsole.error(\"AI response timed out after 20 seconds\");\n\t\t\t\t\terror =\n\t\t\t\t\t\t\"AI response timed out after 20 seconds. Please check if your AI service is running properly.\";\n\t\t\t\t\ttesting = false;","sourceCodeStart":67,"sourceCodeEnd":103,"githubUrl":"https://github.com/gitbutlerapp/gitbutler/blob/58e5313667b857ef39a730e380af31816a7b1768/apps/desktop/src/components/settings/AiCredentialCheck.svelte#L67-L103","documentation":"Validation branch of the AI credential test for the Ollama model kind: validateConfiguration() failed, and the error interpolates the currently configured Ollama endpoint and model name so the user can see which settings are at fault. It typically fires when the Ollama server is unreachable at that endpoint or the configured model name is not available locally.","triggerScenarios":"Thrown at apps/desktop/src/components/settings/AiCredentialCheck.svelte:85 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Start the Ollama server (ollama serve) and confirm it is listening on the configured endpoint","Verify the model exists locally with `ollama list` and correct the model name in AI settings","Check that the endpoint URL and port in AI settings are correct and reachable from the app"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"58e5313667b857ef39a730e380af31816a7b1768","analyzedAt":"2026-09-18T06:50:32.052Z","contentChangedAt":"2026-09-18T06:50:32.052Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}