• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

jhheider / pdcst / 29268038387
67%

Build:
DEFAULT BRANCH: main
Ran 13 Jul 2026 04:53PM UTC
Jobs 1
Files 44
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

13 Jul 2026 04:50PM UTC coverage: 66.781% (+0.3%) from 66.47%
29268038387

push

github

web-flow
feat: persist streamed episodes and resume them with HTTP Range (#34)

Streamed episodes used to download to a temp file in a stream cache that
was purged on every startup, so resuming a partly-heard episode re-opened
the stream from byte 0 and re-buffered from the start (the position was
stored, but playback ignored it because the seek had nothing on disk to
seek into).

Now the stream writes to a persistent `download_dir/{id}.{ext}`:

- A later play (this session or after restart) resumes the download with an
  HTTP `Range: bytes=N-` request from the bytes already on disk. The decoder
  seeks to the saved position, which lands in the already-downloaded region,
  so a resume jumps straight to where you left off with no re-buffer. Handles
  206 (append), 416 (already complete), and a plain 200 (server ignored
  Range -> restart from zero) as a fallback.
- The file keeps its final name whether partial or complete; the episode's
  `Downloaded` status (set on completion) distinguishes them, so there is no
  rename to race the reader.
- On completion the episode is marked `Downloaded` and announced, so it then
  plays straight off disk (`play_from_file`) and normal download retention
  manages it.

Removed the now-defunct `stream_cache_dir` + `stream::purge_all` startup
wipe (and the `RetentionManager` arg for it). AudioStreamer gains the db +
event bus needed to mark completion.

Tests: `open_stream_resumes_partial_via_range` pre-seeds a partial and
asserts a `Range` resume yields the full episode (on-disk prefix +
range-fetched tail); existing stream tests updated.

Known follow-up (noted in ROADMAP): partial files for episodes
started-but-never-finished are not yet retention-counted.


Claude-Session: https://claude.ai/code/session_014meUZPwNWx1cfEub4Ncx3Y

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

134 of 144 new or added lines in 2 files covered. (93.06%)

4 existing lines in 2 files now uncovered.

3892 of 5828 relevant lines covered (66.78%)

2585707.52 hits per line

Uncovered Changes

Lines Coverage ∆ File
6
92.95
1.0% crates/pdcst/src/audio/stream.rs
4
0.0
0.0% crates/pdcst/src/app/mod.rs

Coverage Regressions

Lines Coverage ∆ File
3
68.18
-3.41% crates/pdcst/src/config.rs
1
92.95
1.0% crates/pdcst/src/audio/stream.rs
Jobs
ID Job ID Ran Files Coverage
1 29268038387.1 13 Jul 2026 04:53PM UTC 44
66.78
GitHub Action Run
Source Files on build 29268038387
  • Tree
  • List 44
  • Changed 4
  • Source Changed 3
  • Coverage Changed 4
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #29268038387
  • 1e91cd6c on github
  • Prev Build on main (#29266263278)
  • Next Build on main (#29270488157)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc