fix: Improve Whisper model status error handling
- Set sidecarReady to false when model_error is received - Store error message in activeWhisperConfig for status display - Update frontend to show error state with red indicator - Prevents showing ✅ when model failed to load 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -434,9 +434,15 @@ function startSidecar() {
|
||||
mainWindow.webContents.send("model-download-progress", msg);
|
||||
}
|
||||
|
||||
// Forward model error status
|
||||
if (msg.status === "model_error" && mainWindow) {
|
||||
mainWindow.webContents.send("model-download-progress", msg);
|
||||
// Forward model error status and mark sidecar as not ready
|
||||
if (msg.status === "model_error") {
|
||||
sidecarReady = false;
|
||||
if (activeWhisperConfig) {
|
||||
activeWhisperConfig.error = msg.error || "Model load failed";
|
||||
}
|
||||
if (mainWindow) {
|
||||
mainWindow.webContents.send("model-download-progress", msg);
|
||||
}
|
||||
}
|
||||
} catch (e) {
|
||||
console.log("Sidecar output:", line);
|
||||
|
||||
Reference in New Issue
Block a user