fix(downloader): outlast network outages and harden segment merges

Outage-only retry budget, fail fast on a full disk, rnet read_timeout from config, fixed-size shared range parts, Windows-safe segment deletes, merge benchmark.
This commit is contained in:
imSp4rky
2026-11-23 13:43:38 -07:00
parent 138782f38b
commit 91fbe67fa6
14 changed files with 708 additions and 55 deletions
+2 -1
View File
@@ -884,7 +884,8 @@ class Track:
with save_path.open("wb") as joined, media_path.open("rb") as media:
joined.write(sample_range[0])
shutil.copyfileobj(media, joined)
media_path.unlink()
with contextlib.suppress(OSError):
media_path.unlink()
self.path = save_path
events.emit(events.Types.TRACK_DOWNLOADED, track=self)