{"record":{"id":"1aaa97e4abae7ac7","repo":"SubtitleEdit/subtitleedit","slug":"crispasr-indextts-did-not-report-healthy-within","errorCode":null,"errorMessage":"crispasr (indextts) did not report healthy within {5|15} minutes. Last output: {lastOutput}{LaunchCmdSuffix}","messagePattern":"crispasr \\(indextts\\) did not report healthy within (.+?) minutes\\. Last output: (.+?)(.+?)","errorType":"exception","errorClass":"TimeoutException","httpStatus":null,"severity":"error","filePath":"src/ui/Features/Video/TextToSpeech/Engines/IndexTtsCrispAsr.cs","lineNumber":631,"sourceCode":"                    _serverPort = 0;\n                    _serverLaunchCommand = null;\n                    _serverVoicePath = null;\n                    _serverModelKey = null;\n                    throw new InvalidOperationException(\n                        $\"crispasr (indextts) exited during startup (code {exitCode}). Output: {tail}\"\n                        + LaunchCmdSuffix(exitedLaunchCommand));\n                }\n                if (await ProbeHealthAsync(port, TimeSpan.FromSeconds(2), ct))\n                {\n                    return;\n                }\n                await Task.Delay(TimeSpan.FromSeconds(1), ct);\n            }\n\n            var lastOutput = SnapshotServerLog();\n            var timeoutLaunchCommand = _serverLaunchCommand;\n            StopServerInternal();\n            throw new TimeoutException(\n                $\"crispasr (indextts) did not report healthy within {(hasLocalTalker && hasLocalCodec ? 5 : 15)} minutes. Last output: {lastOutput}\"\n                + LaunchCmdSuffix(timeoutLaunchCommand));\n        }\n        finally\n        {\n            ServerLock.Release();\n        }\n    }\n\n    private static string SnapshotServerLog()\n    {\n        lock (_serverLog)\n        {\n            var s = _serverLog.ToString().TrimEnd();\n            return s.Length > 2000 ? s[^2000..] : s;\n        }\n    }\n","sourceCodeStart":613,"sourceCodeEnd":649,"githubUrl":"https://github.com/SubtitleEdit/subtitleedit/blob/17a9f0748781032255db3526b7215d2fb891e3af/src/ui/Features/Video/TextToSpeech/Engines/IndexTtsCrispAsr.cs#L613-L649","documentation":"TimeoutException from IndexTtsCrispAsr.EnsureServerRunningAsync when the indextts server stays alive but never answers `/health` within the deadline — 5 minutes if BOTH local talker and codec GGUFs are present, 15 minutes otherwise (to allow ~870 MB auto-download). The server is stopped and the last 2000 chars of its log plus launch command are attached.","triggerScenarios":"Model auto-download stalled on a slow/blocked network; the server binds but `/health` deadlocks; loopback firewall blocks the health GET; GPU saturated so init never finishes within the window.","commonSituations":"Proxy-filtered corporate network blocking the model CDN; CrispASR version whose `/health` route changed; concurrent GPU workload; underpowered hardware loading a large quant.","solutions":["Inspect `Last output:` for download/loading progress lines.","Pre-stage both talker and codec GGUFs locally so the 5-minute deadline applies.","Ensure loopback `127.0.0.1` traffic is not firewalled.","Free GPU/CPU resources so the server can finish init.","Run the launch command manually to see how long init truly takes on your machine."],"exampleFix":null,"handlingStrategy":"retry","validationCode":"// Tell users the first-run cost up front\nif (!engine.HasLocalTalker(modelKey) || !engine.HasLocalCodec())\n    WarnUser(\"First run downloads ~870 MB; keep the network stable.\");","typeGuard":null,"tryCatchPattern":"try { await indexEngine.Speak(...); }\ncatch (TimeoutException ex) when (ex.Message.Contains(\"did not report healthy\"))\n{\n    if (await ConfirmRetry()) await indexEngine.Speak(...);\n}","preventionTips":["Pre-stage both talker and codec GGUFs to use the 5-minute deadline.","Keep loopback unblocked by firewall/VPN.","Free GPU/CPU during first run.","Pre-warm with a short test utterance before batch jobs."],"tags":["indextts","crispasr","health-check","timeout","server","tts"],"backgroundTag":null,"analyzedSha":"17a9f0748781032255db3526b7215d2fb891e3af","analyzedAt":"2026-08-13T18:11:43.374Z","schemaVersion":2},"datasetVersion":"2026-08-13T19:17:28.613Z"}