{"record":{"id":"67b57ea73f6f8efe","repo":"Zackriya-Solutions/meetily","slug":"download-failed-for-with-status","errorCode":null,"errorMessage":"Download failed for {} with status: {}","messagePattern":"Download failed for (.+?) with status: (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"frontend/src-tauri/src/parakeet_engine/parakeet_engine.rs","lineNumber":805,"sourceCode":"\n                    // Retry without Range header\n                    log::info!(\"Retrying {} without resume\", filename);\n                    response = client.get(&file_url).send().await\n                        .map_err(|e| anyhow!(\"Retry failed for {}: {}\", filename, e))?;\n\n                    if !response.status().is_success() {\n                        let mut active = self.active_downloads.write().await;\n                        active.remove(model_name);\n                        return Err(anyhow!(\"Retry failed for {} with status: {}\", filename, response.status()));\n                    }\n\n                    (response.content_length().unwrap_or(0), false)\n                }\n            } else {\n                // Other errors\n                let mut active = self.active_downloads.write().await;\n                active.remove(model_name);\n                return Err(anyhow!(\"Download failed for {} with status: {}\", filename, response.status()));\n            };\n\n            // Open file for writing (append if resuming, create new if not)\n            let file = if resuming {\n                fs::OpenOptions::new()\n                    .append(true)\n                    .open(&file_path)\n                    .await\n                    .map_err(|e| anyhow!(\"Failed to open file for resume {}: {}\", filename, e))?\n            } else {\n                fs::File::create(&file_path)\n                    .await\n                    .map_err(|e| anyhow!(\"Failed to create file {}: {}\", filename, e))?\n            };\n\n            // Use buffered writer for better I/O performance (8MB buffer)\n            let mut writer = BufWriter::with_capacity(8 * 1024 * 1024, file);\n","sourceCodeStart":787,"sourceCodeEnd":823,"githubUrl":"https://github.com/Zackriya-Solutions/meetily/blob/0281737d87d26352fb0adc78c8c0975f691b23d1/frontend/src-tauri/src/parakeet_engine/parakeet_engine.rs#L787-L823","documentation":"Returned by download_model_detailed when the FIRST GET for a file returns a non-success HTTP status and it is not the resumable-partial case: the tuple match falls into the 'other errors' arm, removes the model from active_downloads, and fails with the reqwest StatusCode. This covers server-side rejections of the initial request for encoder/decoder/vocab files.","triggerScenarios":"404 because a file like encoder-model.int8.onnx is absent at the versioned base URL (v2 vs v3 layout mismatch); 403 from HuggingFace hotlink/auth policies or geo-blocks; 429 rate limiting right at download start; 5xx from meetily.towardsgeneralintelligence.com during an outage.","commonSituations":"Upstream HuggingFace repo restructured after an app release; the meetily mirror temporarily down; aggressive rate limits after several aborted downloads; region blocked from the CDN.","solutions":["Check which file failed - the '{}' filename plus curl -I on the full URL identifies a moved/missing file vs a server problem","On 429 or 5xx: wait and retry; the engine cleans its active-download state and resumes","On 404/410 persistent: switch to the other catalog model (v2 vs v3 use different hosts) or update the app for corrected URLs","On 403: verify no proxy/VPN is stripping headers and that the network allows the host"],"exampleFix":null,"handlingStrategy":"retry","validationCode":"// Optional preflight HEAD request for the first file of the model\nlet base = if name.contains(\"-v2-\") {\n    \"https://huggingface.co/istupakov/parakeet-tdt-0.6b-v2-onnx/resolve/main\"\n} else {\n    \"https://meetily.towardsgeneralintelligence.com/models/parakeet-tdt-0.6b-v3-onnx\"\n};\nlet resp = reqwest::Client::new().head(format!(\"{base}/vocab.txt\")).send().await?;\nanyhow::ensure!(resp.status().is_success(), \"preflight failed: {}\", resp.status());","typeGuard":null,"tryCatchPattern":"match engine.download_model(name, None).await {\n    Err(e) if e.to_string().contains(\"Download failed for\") && e.to_string().contains(\"status\") => {\n        let msg = e.to_string();\n        if msg.contains(\"429\") || msg.contains(\"500\") || msg.contains(\"502\") || msg.contains(\"503\") {\n            // server-side: retry later with backoff; partial files resume\n        } else {\n            // 403/404: host blocks the request or file moved - switch model/host, do not retry\n        }\n        return Err(e);\n    }\n    other => other?,\n}","preventionTips":["Check the failed filename and its URL with curl before retrying - 404 means the URL, not the network","Avoid repeated cancel/restart cycles that trigger CDN rate limits","If one host is down, use the other model version (v2 on HuggingFace vs v3 on the meetily mirror)"],"tags":["parakeet","http-status","download","huggingface","cdn"],"backgroundTag":"http-error-response","analyzedSha":"0281737d87d26352fb0adc78c8c0975f691b23d1","analyzedAt":"2026-08-16T20:57:52.567Z","schemaVersion":2},"datasetVersion":"2026-08-16T23:17:17.608Z"}