Add per-episode <itunes:image> to RSS feed items #14

Closed
opened 2026-06-19 07:09:52 +00:00 by coding-agent-marvin8 · 1 comment
coding-agent-marvin8 commented 2026-06-19 07:09:52 +00:00 (Migrated from codeberg.org)

Podcast clients can't show per-episode artwork because the feed only sets <itunes:image> at channel level. ytdl-sub writes <stem>.jpg thumbnail files alongside each audio file; these should be reflected as item-level <itunes:image> tags in the RSS feed.

Podcast clients can't show per-episode artwork because the feed only sets `<itunes:image>` at channel level. ytdl-sub writes `<stem>.jpg` thumbnail files alongside each audio file; these should be reflected as item-level `<itunes:image>` tags in the RSS feed.
coding-agent-marvin8 commented 2026-06-19 07:10:17 +00:00 (Migrated from codeberg.org)

Findings: ytdl-sub names thumbnails with the same stem as the audio file and a .jpg extension (e.g. 2026-05-19 - Episode Title.jpg next to .opus). The CLAUDE.md input contract says -thumb.jpg suffix but the live data doesn't use that — will implement against the real data.

Approach:

  1. Add thumbnail_path: Path | None = None field to the Episode dataclass in discovery.py
  2. In discover_episodes(), probe audio_path.with_suffix('.jpg') and set thumbnail_path if it exists
  3. In feed.py _append_episode_item(), emit <itunes:image href="..."/> using the existing build_enclosure_url() helper to construct the URL
  4. TDD: failing tests first in test_discovery.py and test_feed.py, then implementation
**Findings:** ytdl-sub names thumbnails with the same stem as the audio file and a `.jpg` extension (e.g. `2026-05-19 - Episode Title.jpg` next to `.opus`). The CLAUDE.md input contract says `-thumb.jpg` suffix but the live data doesn't use that — will implement against the real data. **Approach:** 1. Add `thumbnail_path: Path | None = None` field to the `Episode` dataclass in `discovery.py` 2. In `discover_episodes()`, probe `audio_path.with_suffix('.jpg')` and set `thumbnail_path` if it exists 3. In `feed.py` `_append_episode_item()`, emit `<itunes:image href="..."/>` using the existing `build_enclosure_url()` helper to construct the URL 4. TDD: failing tests first in `test_discovery.py` and `test_feed.py`, then implementation
Sign in to join this conversation.
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
marvin8/sub2pod#14
No description provided.