{"record":{"id":"7b709b81ec3cb1bc","repo":"Zackriya-Solutions/meetily","slug":"progress-overflow-while-resuming","errorCode":null,"errorMessage":"Progress overflow while resuming {}","messagePattern":"Progress overflow while resuming (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"frontend/src-tauri/src/parakeet_engine/parakeet_engine.rs","lineNumber":925,"sourceCode":"                last_percent = progress.percent;\n                last_report = Instant::now();\n                continue;\n            }\n\n            let file_url = format!(\"{}/{}\", base_url.trim_end_matches('/'), artifact.filename);\n            let range_start = (local_bytes > 0 && local_bytes < artifact.exact_bytes)\n                .then_some(local_bytes);\n            let response = self\n                .send_download_request(&client, &file_url, range_start, active_download)\n                .await?;\n\n            let (response, mut artifact_bytes, append) = match range_start {\n                Some(range_start) => match response.status() {\n                    reqwest::StatusCode::PARTIAL_CONTENT => {\n                        Self::validate_partial_response(&response, range_start, artifact.exact_bytes)?;\n                        confirmed_bytes = confirmed_bytes\n                            .checked_add(range_start)\n                            .ok_or_else(|| anyhow!(\"Progress overflow while resuming {}\", artifact.filename))?;\n                        let progress =\n                            Self::in_flight_progress(confirmed_bytes, total_bytes, 0.0);\n                        if let Some(callback) = &progress_callback {\n                            callback(progress.clone());\n                        }\n                        self.set_downloading_status(model_name, progress.percent).await;\n                        last_percent = progress.percent;\n                        last_report = Instant::now();\n                        (response, range_start, true)\n                    }\n                    reqwest::StatusCode::OK => {\n                        Self::validate_full_response(&response, artifact.exact_bytes)?;\n                        (response, 0, false)\n                    }\n                    reqwest::StatusCode::RANGE_NOT_SATISFIABLE => {\n                        Self::validate_unsatisfied_response(&response, artifact.exact_bytes)?;\n                        let retry = self\n                            .send_download_request(&client, &file_url, None, active_download)","sourceCodeStart":907,"sourceCodeEnd":943,"githubUrl":"https://github.com/Zackriya-Solutions/meetily/blob/a2cb62e827da7ef59f65064c97233efb2313878e/frontend/src-tauri/src/parakeet_engine/parakeet_engine.rs#L907-L943","documentation":"When resuming a partially downloaded artifact, the server returns 206 and the engine credits the already-downloaded range_start bytes to the progress accumulator via checked_add. Overflow here is practically impossible for real file sizes, so this error indicates corrupted size accounting — e.g. range_start derived from a bogus local file size or corrupted artifact totals.","triggerScenarios":"checked_add(confirmed_bytes, range_start) overflows u64 during resume — only reachable if the local partial file's metadata().len() or confirmed_bytes is corrupt/astronomically large (near u64::MAX).","commonSituations":"A corrupted or maliciously enlarged partial file on disk (length near u64::MAX, e.g. sparse/holey file left by a crashed writer); corrupted progress state across artifacts; inconsistent total_bytes vs per-artifact sizes from a bad manifest.","solutions":["Delete the partial artifact file so the download restarts from zero (no resume path taken).","Verify the partial file's real size (ls -l / stat) and remove files with implausible lengths.","Reset the model cache directory entirely and re-download.","If reproducible with normal files, file a bug — checked_add is a safety net and should never fire."],"exampleFix":"// before: bloated/holey partial file triggers overflow-sized resume\n-rw-r--r-- 1 user staff 18446744073709551615 model.int8.onnx  (corrupted)\n// after: remove and restart\nrm \"~/Library/Application Support/Meetily/models/parakeet/model.int8.onnx\"","handlingStrategy":"validation","validationCode":"// verify partial file sizes are plausible before resuming\nlet md = tokio::fs::metadata(&partial_path).await?;\nassert!(md.len() <= artifact.exact_bytes,\n    \"partial {} larger than artifact ({} > {}) — delete it\",\n    partial_path.display(), md.len(), artifact.exact_bytes);","typeGuard":null,"tryCatchPattern":"match download_result {\n    Err(e) if e.to_string().contains(\"Progress overflow while resuming\") => {\n        // corrupted partial/state: restart the artifact from zero\n        delete_partial(model_dir, filename).await?;\n        retry_download().await\n    }\n    other => other,\n}","preventionTips":["Delete partial files whose on-disk size exceeds the artifact's exact_bytes.","Avoid letting multiple app instances download into the same models dir.","Validate local_bytes against exact_bytes before issuing Range requests.","Treat repeated occurrences as an internal invariant bug; file a report."],"tags":["overflow","progress","resume","filesystem"],"backgroundTag":"internal-invariant-violation","analyzedSha":"a2cb62e827da7ef59f65064c97233efb2313878e","analyzedAt":"2026-09-12T11:12:14.152Z","contentChangedAt":"2026-09-12T11:12:14.152Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}